]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ada/ChangeLog
Fix a typo.
[thirdparty/gcc.git] / gcc / ada / ChangeLog
CommitLineData
e4982b64
AC
12011-08-03 Ed Schonberg <schonberg@adacore.com>
2
3 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
4 modified in the source, to prevent spurious warnings when compiling
5 with -gnatg.
6
72011-08-03 Thomas Quinot <quinot@adacore.com>
8
9 * a-except-2005.adb: Minor reformatting.
10
112011-08-03 Ed Schonberg <schonberg@adacore.com>
12
13 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
14 is a renaming declaration in the private part of a package, do not emit
15 a warning that the with_clause could be moved because the renaming may
16 be used in the body or in a child unit.
17
182011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
19
20 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
21 Propagate the Comes_From_Source attribute from the original return
22 object to the renaming.
23
242011-08-03 Jose Ruiz <ruiz@adacore.com>
25
26 * exp_ch7.adb (Build_Raise_Statement): Do not call
27 Raise_From_Controlled_Operation when this routine is not present in
28 the run-time library.
29 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
30 libraries (Ravenscar), tasks are non-terminating, and protected objects
31 and tasks can only appear at library level, so we do not want
32 finalization of protected objects nor tasks.
33 * exp_intr.adb: Minor clarification in comment.
34 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
35 Gen_Output_File_C): Remove references to finalization of library-level
36 objects when using restricted run-time libraries.
37
382011-08-03 Ed Schonberg <schonberg@adacore.com>
39
40 * sem_ch3.adb (Build_Discriminant_Constraints): Set
41 Original_Discriminant only if the parent type is a generic formal.
42
deb8dacc
HK
432011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
44
45 * exp_ch13.adb: Add with and use clause for Targparm;
46 (Expand_N_Free_Statement): Prevent the generation of a custom
47 Deallocate on .NET/JVM targets since this requires pools and address
48 arithmetic.
49 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
50 .NET/JVM targets, attach the newly allocated object to the access
51 type's finalization collection. Do not generate a call to
52 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
53 exist in the runtime.
54 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
55 create a custom Allocate for object that do not require initialization.
56 Attach a newly allocated object to the access type's finalization
57 collection on .NET/JVM.
58 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
59 assignment of controlled types on .NET/JVM. The two hidden pointers
60 Prev and Next and stored and later restored after the assignment takes
61 place.
62 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
63 kludge for .NET/JVM to recognize a particular piece of code coming from
64 Heap_Management and change the call to Finalize into Deep_Finalize.
65 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
66 finalization collections on .NET/JVM only for types derived from
67 Controlled. Separate the association of storage pools with a collection
68 and only allow it on non-.NET/JVM targets.
69 (Make_Attach_Call): New routine.
70 (Make_Detach_Call): New routine.
71 (Process_Object_Declarations): Suppress the generation of
72 build-in-place return object clean up code on .NET/JVM since it uses
73 pools.
74 * exp_ch7.ads (Make_Attach_Call): New routine.
75 (Make_Detach_Call): New routine.
76 * exp_intr.adb Add with and use clause for Targparm.
77 (Expand_Unc_Deallocation): Detach a controlled object from a collection
78 on .NET/JVM targets.
79 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
80 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
81 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
82 names used in finalization.
83
842011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
85
86 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
87 (Attach, Detach): Lock the current task when chaining an object onto a
88 collection.
89
df3e68b1
HK
902011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
91
92 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
93 Rewritten to create the message strings when the exception is not
94 raised by an abort during finalization.
95 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
96 Raise_From_Controlled_Operation and update its associated comment.
97 * a-fihema.ads, a-fihema.adb: New GNAT unit.
98 Ada.Finalization.Heap_Management provides key functionality
99 associated with controlled objects on the heap, their creation,
100 finalization and reclamation. Type Finalization_Collection is
101 effectively a wrapper which sits ontop of a storage pool and performs
102 all necessary bookkeeping for all the objects it contains. Each
103 access-to-controlled or access-to-class-wide type receives a collection
104 as part of its expansion. The compiler generates buffer code and
105 invokes Allocate / Deallocate to create and destroy allocated
106 controlled objects.
107 * a-finali.adb ("="): Removed.
108 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
109 fields Prev and Next.
110 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
111 A library unit with at least one controlled object on the library level
112 has a special finalizer which is invoked by the binder. To signal this,
113 ali files carry field PF.
114 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
115 associated comment on field usage.
116 * a-tags.adb (Get_RC_Offset): Removed.
117 (Needs_Finalization): New routine.
118 * a-tags.ads: Update the structure of the GNAT dispatch tables.
119 Dispatch tables now carry field Needs_Finalization which provides
120 runtime indication whether a type is controlled or has controlled
121 components or both. Remove field RC_Offset.
122 (Get_RC_Offset): Removed along with its associated pragma Export.
123 Since tagged types with controlled components no longer carry hidden
124 field _controller, the special mechanism to retrieve its location is no
125 longer needed.
126 (Needs_Finalization): New routine.
127 * atree.ads, atree.adb (Elist24): New routine.
128 (Set_Elist24): New routine.
129 * atree.h: Add a define clause for Elist24.
130 * bindgen.adb New library-level variable Lib_Final_Built.
131 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
132 presence of a VM target, the routine generates calls to the proper
133 library finalization routine.
134 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
135 targets. Set the correct library finalization routine depending on
136 whether the library has controlled objects or this is a VM compilation.
137 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
138 to library-level finalizers of compiled units in reverse order of
139 elaboration. It also produces exception management code and reraises a
140 potential exception after all units have been finalized.
141 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
142 library-level finalizers of compiled units in reverse order of
143 elaboration.
144 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
145 definitions of all library-level finalizers available to the compilation
146 (Gen_Main_Ada): Directly call Adafinal which now contails all target
147 dependent code.
148 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
149 System.Standard_Library.Adafinal directly. If the library needs
150 finalization actions, create the sequence of finalization calls.
151 (Gen_Output_File_Ada): Alphabetize local variables and constants.
152 Generate a with clause for System.Soft_Links when compiling for a VM.
153 Remove the code which imports System.Standard_Library.Adafinal as
154 Do_Finalize. Generate the library finalization routine.
155 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
156 If the library needs finalization actions, create all the definitions
157 of library- level finalizers.
158 (Has_Finalizer): New routine. Determines whether at least one compiled
159 unit has a library-level finalizer.
160 Add type Qualification_Mode.
161 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
162 * einfo.adb: New usage of field 15 as Return_Flag.
163 Remove Finalization_Chain_Entity from the usages of field 19.
164 Remove Associated_Final_Chain from the usages of field 23.
165 New usage of field 23 as Associated_Collection.
166 New usage of field 24 as Finalizer.
167 New usage of flag 252 as Is_Processed_Transient.
168 (Associated_Final_Chain): Removed.
169 (Associated_Collection): New routine.
170 (Finalization_Chain_Entity): Removed.
171 (Finalizer): New routine.
172 (Is_Finalizer): New routine.
173 (Is_Processed_Transient): New routine.
174 (Return_Flag): New routine.
175 (Set_Associated_Final_Chain): Removed.
176 (Set_Associated_Collection): New routine.
177 (Set_Finalization_Chain_Entity): Removed.
178 (Set_Finalizer): New routine.
179 (Set_Is_Processed_Transient): New routine.
180 (Set_Return_Flag): New routine.
181 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
182 displayed flags.
183 (Write_Field8_Name): Alphabetize the output.
184 (Write_Field11_Name): Alphabetize the output.
185 (Write_Field12_Name): Alphabetize the output.
186 (Write_Field13_Name): Alphabetize the output.
187 (Write_Field14_Name): Alphabetize the output.
188 (Write_Field15_Name): Alphabetize the output.
189 (Write_Field16_Name): Alphabetize the output.
190 (Write_Field17_Name): Alphabetize the output.
191 (Write_Field18_Name): Alphabetize the output.
192 (Write_Field19_Name): Alphabetize the output. Remove the output of
193 Finalization_Chain_Entity.
194 (Write_Field20_Name): Alphabetize the output.
195 (Write_Field21_Name): Alphabetize the output.
196 (Write_Field22_Name): Alphabetize the output.
197 (Write_Field23_Name): Alphabetize the output. Remove the output of
198 Associated_Final_Chain. Add output for Associated_Collection.
199 (Write_Field24_Name): Alphabetize the output.
200 (Write_Field25_Name): Add output for Finalizer.
201 (Write_Field26_Name): Alphabetize the output.
202 (Write_Field27_Name): Alphabetize the output.
203 (Write_Field28_Name): Alphabetize the output.
204 * einfo.ads: Add new field description for Associated_Collection and
205 its uses in nodes.
206 Remove Associated_Final_Chain and its uses in nodes.
207 Remove Finalization_Chain_Entity and its uses in nodes.
208 Add new field description for Finalizer and its uses in nodes.
209 Add new synthesized attribute Is_Finalizer.
210 Add new flag description for Is_Processed_Transient and its uses in
211 nodes.
212 Add new field description for Return_Flag and its uses in nodes.
213 (Associated_Final_Chain): Removed along with its pragma Inline.
214 (Associated_Collection): New routine and pragma Inline.
215 (Finalization_Chain_Entity): Removed along with its pragma Inline.
216 (Finalizer): New routine and pragma Inline.
217 (Is_Finalizer): New routine and pragma Inline.
218 (Is_Processed_Transient): New routine and pragma Inline.
219 (Return_Flag): New routine and pragma Inline.
220 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
221 (Set_Associated_Collection): New routine and pragma Inline.
222 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
223 (Set_Finalizer): New routine and pragma Inline.
224 (Set_Is_Processed_Transient): New routine and pragma Inline.
225 (Set_Return_Flag): New routine and pragma Inline.
226 * exp_aggr.adb: Alphabetize subprograms.
227 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
228 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
229 associated comments. Remove local variables External_Final_List and
230 Attach.
231 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
232 Ancestor. Remove the retrieval of finalization lists. Update the call to
233 Make_Adjust_Call.
234 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
235 lists. Update the call to Late_Expansion.
236 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
237 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
238 (Gen_Assign): Remove the retrieval of the finalization list used to
239 build the assignment. Update the calls to Make_Init_Call and
240 Make_Adjust_Call.
241 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
242 Remove the mechanism to determine attachment levels and finalization
243 list retrieval. Remove the processing for coextensions.
244 (Init_Controller): Removed. Controllers no longer exist.
245 (Late_Expansion): Remove formals Flist and Obj along with their
246 associated comments. Update the calls to Build_Record_Aggr_Code and
247 Build_Array_Aggr_Code.
248 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
249 (Expand_N_Freeze_Entity): Add special processing for finalizers which
250 appear in entry bodies, protected subprograms and task bodies.
251 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
252 * exp_ch3.adb (Add_Final_Chain): Removed.
253 (Build_Array_Init_Proc): Alphabetize local variables.
254 (Build_Assignment): Alphabetize local variables. Update the call to
255 Maked_Adjust_Call.
256 (Build_Class_Wide_Master): Rename local variables to better reflect
257 their role.
258 (Build_Discriminant_Assignments): Code reformatting.
259 (Build_Init_Call_Thru): Code reformatting.
260 (Build_Init_Procedure): Code reformatting. Generate a special version
261 of Deep_Finalize which is capable of finalizing all initialized
262 components and ignore the rest.
263 (Build_Init_Statements): Rename local variables to better reflect their
264 role.
265 Reimplement the mechanism to include the creation and update of an index
266 variable called a "counter". It is used as a bookmark for tracing
267 initialized and non-initialized components.
268 (Build_Initialization_Call): Remove local variable Controller_Typ.
269 Alphabetize all local variables. Remove the initialization of the
270 record controller and update the call to Make_Init_Call.
271 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
272 New local variable Counter.
273 (Constrain_Array): Alphabetize.
274 (Expand_Freeze_Array_Type): Create a collection instead of a
275 finalization list.
276 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
277 Finalize_Address which is used in conjunction with allocated controlled
278 objects.
279 (Expand_N_Object_Declaration): Remove the creation of a finalization
280 list for anonymous access types. Update the calls to Make_Init_Call and
281 Make_Adjust_Call.
282 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
283 retrieval of finalization lists. Remove the expansion of the record
284 controller. Create TSS primitive Finalize_Address used in conjunction
285 with controlled objects on the heap. Create finalization collections
286 for access-to-controlled record components.
287 (Expand_Record_Controller): Removed.
288 (Freeze_Type): Remove the freezing of record controllers. Freezing of
289 class-wide types now requires additional processing. Create
290 finalization collections for access-to-controlled types.
291 (Increment_Counter): New routine.
292 (Make_Counter): New routine.
293 (Make_Eq_If): Remove the mention of Name_uController.
294 (Make_Predefined_Primitive_Specs): There is no longer need to skip
295 types coming from System.Finalization_Root.
296 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
297 (Predefined_Primitive_Bodies): There is no longer need to skip types
298 coming from System.Finalization_Root.
299 (Stream_Operation_OK): Do not generate stream routines for
300 type Ada.Finalization.Heap_Management.Finalization_Collection.
301 * exp_ch3.ads: Alphabetize subprograms.
302 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
303 Add with and use clause for Lib.
304 (Complete_Coextension_Finalization): Removed.
305 (Complete_Controlled_Allocation): New routine. Create a finalization
306 collection for anonymous access-to-controlled types. Create a custom
307 Allocate which interfaces with the back end and the machinery in
308 Heap_Management.
309 (Expand_Allocator_Expression): Add necessary calls to
310 Complete_Controlled_Allocation. Remove the retrieval of finalization
311 lists. Update the calls to Make_Adjust_Call. Generate a call to
312 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
313 the associated collection.
314 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
315 Code clean up. Remove the retrieval of finalization lists and
316 attachment levels.
317 Update the call to Make_Init_Call. Generate a call to
318 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
319 the associated collection.
320 (Get_Allocator_Final_List): Removed. Finalization lists are not
321 available.
322 (Suitable_Element): Remove the mention of Name_uController.
323 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
324 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
325 the left hand side, carry out the assignment and adjust the left hand
326 side.
327 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
328 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
329 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
330 BIP_Collection and BIPcollection.
331 (Build_Heap_Allocator): New routine used to allocate the return object
332 of a build-in-place function onto a collection.
333 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
334 (Expand_Call): Do not replace direct calls to Deep routines with their
335 aliases.
336 (Expand_N_Extended_Return_Statement): Give all variables shorter names
337 and update their occurrences. Add a special return flag to monitor the
338 [ab]normal execution of the function. The flag is set right before the
339 return statement.
340 Rewrite the mechanism used to allocate a build-in-place return object
341 on the heap or on a storage pool.
342 (Is_Direct_Deep_Call): New routine.
343 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
344 build-in-place function call instead of a final list. Build a call to
345 Set_Finalize_Address_Ptr to decorate the associated collection.
346 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
347 order to name the build-in-place function call's result for later
348 finalization. Add a collection to a build-in-place function call
349 instead of a final list.
350 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
351 build-in-place function call instead of a final list. Remove the code
352 which moves one final list and transforms it into the actual in a
353 nested build-in-place call.
354 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
355 build-in-place function call instead of a final list.
356 (Move_Final_List): Removed.
357 (Needs_BIP_Collection): New routine.
358 (Needs_BIP_Final_List): Removed.
359 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
360 enumeration type BIP_Formal_Kind.
361 Update the related comment.
362 (Needs_BIP_Collection): New routine.
363 (Needs_BIP_Final_List): Removed.
364 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
365 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
366 majority of subprograms in this unit. Add Name_Finalize_Address to
367 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
368 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
369 statements for an array type.
370 (Build_Adjust_Statements): Create the adjust statements for a record
371 type.
372 (Build_Cleanup_Statements): New routine. A procedure which given any
373 construct containing asynchronous calls, references to _master, or is a
374 task body, a task allocation or a protected body produces the necessary
375 runtime calls to clean up these constructs.
376 (Build_Exception_Handler): New routine.
377 (Build_Final_List): Removed.
378 (Build_Finalization_Collection): New routine. A core procedure which
379 creates a collection to service heap allocated controlled objects
380 associated with an access-to-controlled type.
381 (Build_Finalize_Statements): Create the finalization statements for a
382 record types.
383 (Build_Finalizer): New routine. A core procedure which given any
384 construct with declarations and/or statements detects all objects which
385 need any type of clean up (controlled objects, protected objects) and
386 generates all necessary code to clean up the said objects in the proper
387 order.
388 (Build_Finalizer_Call): New routine.
389 (Build_Initialize_Statements): Create the initialization statements for
390 an array type. The generated routine contains code to finalize partially
391 initialized arrays.
392 (Build_Object_Declarations): New routine.
393 (Build_Raise_Statement): New routine.
394 (Clean_Simple_Protected_Objects): Removed.
395 (Controller_Component): Removed.
396 (Enclosing_Function): New routine.
397 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
398 either declarations or statements or both.
399 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
400 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
401 package.
402 (Find_Final_List): Removed.
403 (Global_Flist_Ref): Removed.
404 (In_Finalization_Root): Removed.
405 (Insert_Actions_In_Scope_Around): Determine the range of the transient
406 scope in terms of tree nodes. Process all transient variables within
407 that range.
408 (Make_Adjust_Call): Rewritten. There is no longer an attach call
409 generated after the adjust.
410 (Make_Attach_Call): Removed.
411 (Make_Call): New routine.
412 (Make_Clean): Removed.
413 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
414 build routines.
415 (Make_Deep_Proc): Rewritten to generate the new profile signature used
416 in Deep routines.
417 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
418 build routines.
419 (Make_Final_Call): Modified to simply create a call to either
420 Deep_Finalize or Finalize.
421 (Make_Finalize_Address_Body): New routine.
422 (Make_Finalize_Address_Stmts): New routine. A function which produces
423 TSS primitive Finalize_Address used in conjunction with heap allocated
424 controlled objects.
425 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
426 (Make_Init_Call): Rewritten. There is no longer an attach call
427 generated after initialization.
428 (Make_Local_Deep_Finalize): New routine.
429 (Make_Set_Finalize_Address_Ptr_Call): New routine.
430 (Make_Transient_Block): Remove the finalization list retrieval and
431 manipulation.
432 (Needs_Finalization): Moved to Exp_Util.
433 (Parent_Field_Type): New routine.
434 (Preprocess_Components): New routine.
435 (Process_Transient_Objects): New routine.
436 (Wrap_HSS_In_Block): New routine.
437 (Wrap_Transient_Declaration): Remove finalization list management and
438 controller insertion.
439 (Wrap_Transient_Expression): Code reformatting.
440 (Wrap_Transient_Statement): Code reformatting.
441 * exp_ch7.ads (Build_Final_List): Removed.
442 (Build_Finalization_Collection): New routine.
443 (Build_Raise_Statement): New routine.
444 (Controller_Component): Removed.
445 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
446 (Find_Final_List): Removed.
447 (In_Finalization_Root): Removed.
448 (Is_Simple_Protected_Type): Update related comment.
449 (Make_Adjust_Call): New parameter profile and associated comments.
450 (Make_Attach_Call): Removed.
451 (Make_Final_Call): New parameter profile and associated comments.
452 (Make_Finalize_Address_Body): New routine.
453 (Make_Init_Call): New parameter profile and associated comments.
454 (Make_Local_Deep_Finalize): New routine.
455 (Make_Set_Finalize_Address_Ptr_Call): New routine.
456 (Needs_Finalization): Moved to Exp_Util.
457 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
458 (Expand_N_Protected_Body): Remove the handling of finalization lists.
459 (Find_Protection_Type): Moved to Exp_Util.
460 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
461 (Make_DT): Update sequence of dispatch table initialization. Remove the
462 initialization of field RC_Offset. Add initialization of field Needs_
463 Finalization.
464 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
465 Reimplement how an object is first finalized, then deallocated.
466 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
467 Code reformatting.
468 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
469 Register TSS_Finalize_Address with type TSS_Names.
470 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
471 procedure provides the interface between an allocation / deallocation
472 and the support machinery in Ada.Finalization.Heap_Management.
473 (Find_Init_Call): Code reformatting.
474 (Find_Init_Call_In_List): Code reformatting.
475 (Find_Protection_Type): Moved from Exp_Ch9.
476 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
477 (Has_Controlled_Coextensions): Removed.
478 (Has_Controlled_Objects): New routine.
479 (In_Library_Level_Package_Body): New routine.
480 (Insert_Action_After): New routine.
481 (Is_Finalizable_Transient): New routine. This predicate determines
482 whether an object declaration is one of the many variants of controlled
483 transients.
484 (Is_Null_Access_BIP_Func_Call): New routine.
485 (Is_Non_BIP_Func_Call): New routine.
486 (Is_Related_To_Func_Return): New routine.
487 (Needs_Finalization): Moved from Exp_Ch7.
488 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
489 (Find_Protection_Type): Moved from Exp_Ch9.
490 (Has_Controlled_Coextensions): Removed.
491 (Has_Controlled_Objects): New routine.
492 (In_Library_Level_Package_Body): New routine.
493 (Insert_Action_After): New routine.
494 (Is_Finalizable_Transient): New routine.
495 (Is_Null_Access_BIP_Func_Call): New routine.
496 (Is_Non_BIP_Func_Call): New routine.
497 (Is_Related_To_Func_Return): New routine.
498 (Needs_Finalization): Moved from Exp_ch7.
499 * expander.adb (Expand): Add a case for N_Free_Statement.
500 * freeze.adb (Freeze_All): Replace the generation of a finalization
501 list with a collection for access-to-controlled types.
502 (Freeze_Entity): Code reformatting.
503 (Freeze_Record_Type): Remove the freezing of a record controller
504 component.
505 (Freeze_Subprogram): Code reformatting.
506 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
507 finalization list.
508 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
509 has a library-level finalizer.
510 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
511 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
512 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
513 files. Add a-fihema to the list of object files.
514 * par-ch4.adb:
515 Alphabetize the associations in type Is_Parameterless_Attribute.
516 * rtsfind.ads: Ada.Finalization_List.Controller and
517 System.Finalization_Implementation are no longer a GNAT unit.
518 Update the range of type Ada_Finalization_Child. Remove the following
519 recoverable entities:
520
521 RE_Attach_To_Final_List
522 RE_Deep_Tag_Attach
523 RE_Finalize_List
524 RE_Finalize_One
525 RE_Finalizable_Ptr_Ptr
526 RE_Global_Final_List
527 RE_Limited_Record_Controller
528 RE_List_Controller
529 RE_Move_Final_List
530 RE_Record_Controller
531 RE_Simple_List_Controller
532
533 Add the following recoverable entities:
534
535 RE_Add_Offset_To_Address
536 RE_Allocate
537 RE_Base_Pool
538 RE_Deallocate
539 RE_Exception_Identity
540 RE_Finalization_Collection
541 RE_Finalization_Collection_Ptr
542 RE_Needs_Finalization
543 RE_Save_Library_Occurrence
544 RE_Set_Finalize_Address_Ptr
545 RE_Set_Storage_Pool_Ptr
546 RE_Storage_Count
547 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
548 Name_uController.
549 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
550 (First_Stored_Discriminant): Remove the mention of Name_uController.
551 * sem_aux.ads: Comment reformatting.
552 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
553 to redecorate an already existing class-wide type.
554 (Decorate_Tagged_Type): New parameter profile and associated comment.
555 Create a "shadow class-wide type" for a shadow entity.
556 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
557 of the final chain along with the associated comment.
558 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
559 Full_Desig and set it to the full view of the designated type.
560 Initialize the finalization collection to empty.
561 (Build_Derived_Record_Type): Alphabetize local variables. Code
562 reformatting.
563 (Collect_Fixed_Components): Remove the mention of Name_uController.
564 (Create_Constrained_Components): Remove the mention of Name_uController.
565 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
566 class-wide type of a shadow entity.
567 (Process_Full_View): Update the machinery which marks type
568 Limited_Controlled's entity as limited.
569 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
570 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
571 list, instead make a collection build-in-place formal.
572 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
573 a designated type in order to establish a match between the renaming
574 and the renamed entity.
575 (Find_Selected_Component): Add guard to prevent spurious exceptions
576 from being raised on .NET/JVM.
577 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
578 to the list of primitive that need special processing. Update arrays
579 C_Names and D_Names.
580 (Replace_Types): Handle class-wide types.
581 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
582 different parameter profile, look at the first formal.
583 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
584 use clauses for Exp_Util.
585 * sem_res.adb: Remove with and use clauses for Elists.
586 (Propagate_Coextensions): Removed.
587 (Resolve_Allocator): Do not propagate the list of coextensions from one
588 allocator to another.
589 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
590 Deaccessed_T to Desig_Typ.
591 (Enter_Name): Remove the mention of Name_uController.
592 (Gather_Components): Remove the mention of Name_uController.
593 (Incomplete_Or_Private_View): New routine.
594 (Is_Coextension_Root): Removed.
595 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
596 * sem_util.ads (Incomplete_Or_Private_View): New routine.
597 (Is_Coextension_Root): Removed.
598 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
599 Controlled types are now derived from a null tagged record. Remove
600 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
601 * sinfo.adb (Coextensions): Removed.
602 (Set_Coextensions): Removed.
603 * sinfo.ads: Remove Coextensions from the explanation of node fields
604 and its uses in nodes.
605 Update the field usage of N_Allocator.
606 (Coextensions): Removed along with its pragma Inline.
607 (Set_Coextensions): Removed along with its pragma Inline.
608 * snames.ads-tmpl: Remove names
609
610 Name_uClean
611 Name_uController
612 Name_uFinal_List
613 Name_uLocal_Final_List
614 Name_Finalization_Root
615 Name_Next
616 Name_Prev
617
618 Add names
619
620 Name_uFinalizer
621 Name_Finalize_Address
622 * s-pooglo.adb (Allocate): Add overriding indicator.
623 (Deallocate): Add overriding indicator.
624 (Storage_Size): Add overriding indicator.
625 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
626 than Finalize_Global_List.
627 (Null_Finalize_Global_List): Removed.
628 (Save_Library_Occurrence): New routine.
629 * s-soflin.ads: Remove variable Finalize_Global_List along with its
630 initialization. Add variable Finalize_Library_Objects along with its
631 pragma Export. Add variables Library_Exception and
632 Library_Exception_Set along with their pragma Export.
633 (Null_Finalize_Global_List): Removed.
634 (Save_Library_Occurrence): New routine.
635 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
636 rather than Finalize_Global_List.
637 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
638 of the constructed node.
639
2ee06322
RO
6402011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
641
642 * link.c: Include "auto-host.h" before system headers.
643
f77b022b
VC
6442011-08-03 Vincent Celier <celier@adacore.com>
645
646 * make.adb (Gnatmake): Add to table Library_Projs only library projects
647 that are not extended. Do not check if a library project that is
648 extended should be regenerated. Do not add to table Library_Paths the
649 libraries that are in extended projects. Link only with libraries that
650 are in libray projects that are not extended.
651 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
652 for a library project that is extended.
653
0187b60e
AC
6542011-08-03 Gary Dismukes <dismukes@adacore.com>
655
656 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
657 conforming subprogram renamings that appear to be completions if they
658 are not fully conformant.
659 Such renamings are homographs but not completions.
660 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
661 names in a subprogram renaming that appears in an instance.
662
6632011-08-03 Ed Schonberg <schonberg@adacore.com>
664
665 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
666 not immutably limited, build actual subtype from expression to provide
667 proper bounds to caller.
668
6692011-08-03 Gary Dismukes <dismukes@adacore.com>
670
671 * sem_ch8.adb: Minor comment correction.
672
6732011-08-03 Thomas Quinot <quinot@adacore.com>
674
675 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
676 returning a limited array, use an extended return statement.
677
6782011-08-03 Vincent Celier <celier@adacore.com>
679
680 * make.adb (Initialize): If --subdirs= is used, but no project file is
681 specified, attempt to create the specify subdir if it does not already
682 exist and use it as the object directory as if -D had been specified.
683
6842011-08-03 Arnaud Charlet <charlet@adacore.com>
685
686 * s-tpopsp-vms.adb: New file.
687 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
688 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
689
e280f981
AC
6902011-08-03 Emmanuel Briot <briot@adacore.com>
691
692 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
693 package.
694
6952011-08-03 Yannick Moy <moy@adacore.com>
696
697 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
698 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
699 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
700 detect that an array has static bounds.
701
98c99a5a
AC
7022011-08-03 Thomas Quinot <quinot@adacore.com>
703
704 * exp_dist.adb: Minor reformatting.
705
7062011-08-03 Arnaud Charlet <charlet@adacore.com>
707
708 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
709 (ATCB_Key): Removed, not always used.
710
7112011-08-03 Emmanuel Briot <briot@adacore.com>
712
713 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
714 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
715 most remaining global variables.
716
686d0984
AC
7172011-08-03 Robert Dewar <dewar@adacore.com>
718
719 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
720 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
721 reformatting.
722
7232011-08-03 Javier Miranda <miranda@adacore.com>
724
725 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
726 that must be passed by copy in VM targets.
727
7282011-08-03 Emmanuel Briot <briot@adacore.com>
729
730 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
731 duplicates a similar htable now in the project tree.
732
7332011-08-03 Claire Dross <dross@adacore.com>
734
735 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
736 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
737 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
738 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
739 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
740 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
741 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
742 update.
743
7442011-08-03 Arnaud Charlet <charlet@adacore.com>
745
746 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
747 (ATCB_Key): Removed, not always used.
748 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
749 s-taprop-posix.adb.
750 * s-tpopsp-tls.adb: New file.
751 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
752 x86/x64/ia64/powerpc/sparc Linux.
753
7542011-08-03 Arnaud Charlet <charlet@adacore.com>
755
756 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
757 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
758
7592011-08-03 Thomas Quinot <quinot@adacore.com>
760
761 * rtsfind.ads, exp_dist.adb, exp_dist.ads
762 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
763 Fix type selection for mapping integer types to PolyORB types.
764
7652011-08-03 Bob Duff <duff@adacore.com>
766
767 * sem_ch7.adb: Minor comment clarification.
768
7692011-08-03 Bob Duff <duff@adacore.com>
770
771 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
772 an error analyzing a choice, skip further processing. Further
773 processing could cause a crash or cascade errors.
774
40ecf2f5
EB
7752011-08-03 Emmanuel Briot <briot@adacore.com>
776
777 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
778 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
779 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
780 prj-env.ads (Shared_Project_Tree_Data): new type
781 An aggregate project and its aggregated trees need to share the common
782 data structures used for lists of strings, packages,... This makes the
783 code simpler since otherwise we have to pass the root tree (also used
784 for the configuration file data) in addition to the current project
785 tree. This also avoids ambiguities as to which tree should be used.
786 And finally this saves a bit of memory.
787 (For_Every_Project_Imported): new parameter Tree.
788 Since aggregated projects are using a different tree, we need to let
789 the caller know which tree to use to manipulate the returned project.
790
9fde638d
RD
7912011-08-03 Robert Dewar <dewar@adacore.com>
792
793 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
794 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
795 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
796 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
797
95eb8b69
AC
7982011-08-03 Javier Miranda <miranda@adacore.com>
799
800 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
801 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
802
8032011-08-03 Bob Duff <duff@adacore.com>
804
805 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
806 the Base_Type.
807
8082011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
809
810 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
811 g-sehash.ads: Fix typo. Update header.
812
8132011-08-03 Thomas Quinot <quinot@adacore.com>
814
815 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
816 expansion.
817
8182011-08-03 Gary Dismukes <dismukes@adacore.com>
819
820 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
821 prefixes of private types along with records, since the selector may be
822 a discriminant.
823 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
824 private types along with records, since the selector may be a
825 discriminant.
826
92e77027
AC
8272011-08-03 Emmanuel Briot <briot@adacore.com>
828
829 * prj-pp.adb (Pretty_Print): remove trailing blank line in the file
830
8312011-08-03 Javier Miranda <miranda@adacore.com>
832
833 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
834 Tagged_Type_Expansion.
835
8362011-08-03 Yannick Moy <moy@adacore.com>
837
838 * sem_res.adb
839 (Resolve_Op_Concat_Arg): do not issue a SPARK violation when argument of
840 concatenation is the name of a constant
841
ab29a348
EB
8422011-08-03 Emmanuel Briot <briot@adacore.com>
843
844 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
845 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
846 (Process_Declarative_Items): new parameter Child_Env.
847
9466892f
AC
8482011-08-03 Yannick Moy <moy@adacore.com>
849
850 * alfa.ads Update format of ALFA section in ALI file in order to add a
851 mapping from bodies to specs when both are present
852 (ALFA_Scope_Record): add components for spec file/scope
853 * get_alfa.adb (Get_ALFA): read the new file/scope for spec when present
854 * lib-xref-alfa.adb
855 (Collect_ALFA): after all scopes have been collected, fill in the spec
856 information when relevant
857 * put_alfa.adb (Put_ALFA): write the new file/scope for spec when
858 present.
859
8602011-08-03 Eric Botcazou <ebotcazou@adacore.com>
861
862 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
863 code unit to decide whether to add internally generated subprograms.
864
8652011-08-03 Javier Miranda <miranda@adacore.com>
866
867 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
868 * exp_ch9.adb
869 (Build_Simple_Entry_Call): Handle actuals that must be handled by copy
870 in VM targets.
871
8722011-08-03 Emmanuel Briot <briot@adacore.com>
873
874 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): now shares
875 code with Makeutl.Get_Switches.
876 * prj-tree.adb: Update comment.
877
b5ea9143
AC
8782011-08-03 Thomas Quinot <quinot@adacore.com>
879
880 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
881 subprogram with a limited formal that does not support external
882 streaming.
883
8842011-08-03 Yannick Moy <moy@adacore.com>
885
886 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
887 continuation line
888 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
889 not from current unit in two phases, because it is not possible to
890 change the table while iterating over its content.
891 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
892
8932011-08-03 Sergey Rybin <rybin@adacore.com>
894
895 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
896 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
897
668a19bc
ES
8982011-08-03 Ed Schonberg <schonberg@adacore.com>
899
900 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
901 and the component type is composite, this is ambiguous for predefined
902 concatenation, but if the node is not overloaded and the entity is a use
903 -defined function its profile can be used to resolve that aggregate.
904
170b2989
AC
9052011-08-03 Robert Dewar <dewar@adacore.com>
906
907 * exp_ch4.adb: Minor code cleanup.
908
9092011-08-03 Thomas Quinot <quinot@adacore.com>
910
911 * exp_dist.adb: Do not generate distribution stubs if serious errors
912 have been diagnosed.
913
9142011-08-03 Ed Schonberg <schonberg@adacore.com>
915
916 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
917 the first formal of a primitive operation, go to the base type to
918 handle properly an access to a derived type with constrained
919 discriminants.
920 * sem_type.adb (Disambiguate): an immediately visible operator hides a
921 user-defined function that is only use-visible.
170b2989 922
e917aec2
RD
9232011-08-03 Robert Dewar <dewar@adacore.com>
924
925 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
926 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
927 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
928 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
929 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
930 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
931 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
932 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
933
9342011-08-03 Robert Dewar <dewar@adacore.com>
935
936 * repinfo.adb (List_Mechanism): Add handling of
937 Convention_Ada_Pass_By_XXX.
938 * sem_mech.adb (Set_Mechanism): Ditto.
939 * sem_prag.adb (Process_Convention): Add entries for
940 Convention_Ada_Pass_By_XXX.
941 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
942
49bfcf43
AC
9432011-08-03 Pascal Obry <obry@adacore.com>
944
945 * makeutl.adb: Minor reformatting.
946
9472011-08-03 Vincent Celier <celier@adacore.com>
948
949 * fname-uf.adb
950 (Get_File_Name) If the file cannot be found when there are no config
951 pragmas file and May_Fail is True, return No_File instead of the file
952 name, to be consistent.
953
9542011-08-03 Pascal Obry <obry@adacore.com>
955
956 * adaint.c (__gnat_is_executable_file_attr): Avoid access
957 to null pointer.
958
9592011-08-03 Javier Miranda <miranda@adacore.com>
960
961 * sem_ch13.adb
962 (Same_Representation): In VM targets the representation of arrays with
963 aliased components differs from arrays with non-aliased components.
964
34798441
EB
9652011-08-03 Emmanuel Briot <briot@adacore.com>
966
967 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
968 not systematically lower case attribute indexes that contain no "."
969 Fix definition of several Naming attributes, which take
970 a unit name as index and therefore should be case insensitive.
971 Minor refactoring (reduce length of variable names).
972
9732011-08-03 Emmanuel Briot <briot@adacore.com>
974
975 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
976
4437a530
EB
9772011-08-03 Emmanuel Briot <briot@adacore.com>
978
979 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
980 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
981 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
982 prj-tree.ads (Prj.Tree.Environment): new type.
983
804fe3c4
EB
9842011-08-03 Emmanuel Briot <briot@adacore.com>
985
986 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
987 prj-tree.adb, prj-tree.ads (Environment): new type.
988
c565bc66
AC
9892011-08-03 Emmanuel Briot <briot@adacore.com>
990
991 * prj-tree.ads: Remove unused variable.
992
9932011-08-03 Yannick Moy <moy@adacore.com>
994
995 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
996 issuing messages related to SPARK restriction violation.
997
4ee646da
AC
9982011-08-03 Ed Schonberg <schonberg@adacore.com>
999
1000 * sem_ch6.adb: guard against error nodes in return statements.
1001
10022011-08-03 Arnaud Charlet <charlet@adacore.com>
1003
1004 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
1005 a warning can only appear on a configuration file, so emit warning
1006 without further checks.
1007
10082011-08-03 Arnaud Charlet <charlet@adacore.com>
1009
1010 * s-interr.ads: add overriding keyword.
1011
10122011-08-03 Geert Bosch <bosch@adacore.com>
1013
1014 * exp_attr.adb: Fix minor typo.
1015
10162011-08-03 Ed Schonberg <schonberg@adacore.com>
1017
1018 * par-ch4.adb: improve error recovery.
1019
c0e538ad
AC
10202011-08-03 Emmanuel Briot <briot@adacore.com>
1021
1022 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
1023 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
1024 to Errout_Handling.
1025
10262011-08-03 Emmanuel Briot <briot@adacore.com>
1027
1028 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
1029 "external" as an attribute name in aggregate projects.
1030
10312011-08-03 Jose Ruiz <ruiz@adacore.com>
1032
1033 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
1034 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
1035 from 0, so we need to adjust.
1036
10372011-08-03 Emmanuel Briot <briot@adacore.com>
1038
1039 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
1040 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
1041
c4d67e2d
AC
10422011-08-03 Yannick Moy <moy@adacore.com>
1043
1044 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
1045 restriction on overloaded entity if the entity is not an operator.
1046
10472011-08-03 Yannick Moy <moy@adacore.com>
1048
1049 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
1050 restrict.ads: Rename remaining Check_Formal_Restriction* into
1051 Check_SPARK_Restriction*.
1052
10532011-08-03 Emmanuel Briot <briot@adacore.com>
1054
1055 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
1056 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
1057 qualifier.
1058 (Project_Empty): removed
1059 (Empty_Project): new parameter Qualifier
1060 This is used to have fields specific to aggregate projects, cleaner
1061 New field to store the list of aggregated projects.
1062 (Check_Aggregate_Project): removed
1063 (Process_Aggregated_Projects, Free): new subprograms.
1064
3f5a8fee
AC
10652011-08-03 Olivier Hainque <hainque@adacore.com>
1066
1067 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
1068
10692011-08-03 Ed Schonberg <schonberg@adacore.com>
1070
1071 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
1072 explicit dereference of an unconstrained type, create a constrained
1073 subtype for it, as is done for function calls that return an
1074 unconstrained type.
1075
10762011-08-03 Thomas Quinot <quinot@adacore.com>
1077
1078 * g-pehage.adb (Finalize): Avoid possible double-free.
1079
10802011-08-03 Steve Baird <baird@adacore.com>
1081
1082 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
1083 Elab_Spec/Body attrs in CodePeer_Mode.
1084
10852011-08-03 Javier Miranda <miranda@adacore.com>
1086
1087 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
1088 low bound is not known at compile time but they have no others choice.
1089 Done because in this case the bounds can be obtained directly from the
1090 aggregate.
1091
10922011-08-03 Ed Falis <falis@adacore.com>
1093
1094 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
1095 on VxWorks SMP. Remove unusable constant ANY_CPU.
1096
a96ca600
EB
10972011-08-03 Emmanuel Briot <briot@adacore.com>
1098
1099 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
1100 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
1101 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
1102 Prj.Env.Initialize_Empty): new subprograms
1103 (Get_Env, Find_Project): remove parameter Target_Name.
1104
3e582869
AC
11052011-08-03 Gary Dismukes <dismukes@adacore.com>
1106
1107 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
1108 as a condition for the delayed call to Derived_Subprograms done for the
1109 case of the rewriting of a derived type that constrains the
1110 discriminants of its parent type.
1111 Avoids redundant subprogram derivations for private subtype derivations.
1112
11132011-08-03 Javier Miranda <miranda@adacore.com>
1114
1115 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
1116 Build_Record_Aggr_Code.
1117 (Build_Record_Aggr_Code): Add missing support to initialize hidden
1118 discriminants in extension aggregates.
1119
11202011-08-03 Emmanuel Briot <briot@adacore.com>
1121
1122 * prj-pp.adb (Print): also output project qualifiers, since in
1123 particular "aggregate" is mandatory in an aggregate project.
1124
11252011-08-03 Emmanuel Briot <briot@adacore.com>
1126
1127 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
1128 (Debug_Output): new function.
1129
56e94186
AC
11302011-08-03 Eric Botcazou <ebotcazou@adacore.com>
1131
1132 * gnat_ugn.texi: Document -Wstack-usage.
1133 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
1134
11352011-08-03 Thomas Quinot <quinot@adacore.com>
1136
1137 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
1138 have keyword LIMITED.
1139
11402011-08-03 Yannick Moy <moy@adacore.com>
1141
1142 * alfa.adb, alfa.ads, alfa_test.adb: New files.
1143 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
1144 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
1145 section (does not happen in compiler, only if code directly calls
1146 Scan_ALI).
1147 * get_alfa.adb, get_alfa.ads: New files.
1148 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
1149 needed.
1150 * lib-xref-alfa.adb: New file.
1151 * lib-xref.adb, lib-xref.ads
1152 (Xref_Entry): redefine information needed in cross-references for ALFA.
1153 Push ALFA treatments in separated local package.
1154 (Enclosing_Subpragram_Or_Package): treat specially subprogram
1155 identifiers. Return entity of package body instead of spec. Return
1156 Empty for a scope with no location.
1157 (Generate_Reference): adapt to new components for ALFA information.
1158 Remove the need for D references on definitions.
1159 (Is_Local_Reference): moved to ALFA local package
1160 (Output_References): extract subfunction as Extract_Source_Name
1161 (Output_Local_References): remove procedure, replaced by filtering of
1162 cross-references in package ALFA and printing in Put_ALFA.
1163 (Write_Entity_Name): remove procedure
1164 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
1165 print exact name of entity as it appears in source file
1166 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
1167 * put_alfa.adb, put_alfa.ads: New files.
1168 * xref_lib.adb (Search_Xref): protect read of cross-references against
1169 reading other sections of the ALI file, in gnatxref
1170 (Search): protect read of cross-references against reading other
1171 sections of the ALI file, in gnatfind.
1172 * gcc-interface/Make-lang.in: Update dependencies.
1173
11742011-08-03 Thomas Quinot <quinot@adacore.com>
1175
1176 * sem_ch3.adb: Minor reformatting.
1177
11782011-08-03 Jose Ruiz <ruiz@adacore.com>
1179
1180 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
1181 raising an exception.
1182
11832011-08-03 Ed Schonberg <schonberg@adacore.com>
1184
1185 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
1186 type, always use 1 as the lower bound or string, even if lower bound of
1187 context is not static, to handle properly null strings in a non-static
1188 context.
1189
11902011-08-03 Bob Duff <duff@adacore.com>
1191
1192 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
1193 always legal on the right-hand side of an assignment statement; there
1194 is always an applicable index constraint in this case. Therefore, the
1195 check for Pkind = N_Assignment_Statement is now unconditional -- it
1196 doesn't depend on whether Is_Constrained (Typ).
1197
4317e442
AC
11982011-08-03 Robert Dewar <dewar@adacore.com>
1199
1200 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
1201
12022011-08-03 Ed Schonberg <schonberg@adacore.com>
1203
1204 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
1205 for an itype created within a generic unit.
1206
12072011-08-03 Eric Botcazou <ebotcazou@adacore.com>
1208
1209 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
1210 suppresses all inlining.
1211
53f29d4f
AC
12122011-08-03 Robert Dewar <dewar@adacore.com>
1213
1214 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
1215 exp_aggr.adb: Minor reformatting.
1216
12172011-08-03 Thomas Quinot <quinot@adacore.com>
1218
1219 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
1220 tagged assignment when discriminant checks are suppressed. This is
1221 useless and extremely costly in terms of static stack usage.
1222
12232011-08-03 Bob Duff <duff@adacore.com>
1224
1225 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
1226 of generics, because this leads to the wrong entity in the wrong scope,
1227 causing (e.g.) pragma Export_Procedure to get an error if the entity is
1228 an instance.
1229 (Process_Interface_Name): Follow Alias for instances of generics, to
1230 correct for the above change.
1231
12322011-08-03 Ed Schonberg <schonberg@adacore.com>
1233
1234 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
1235 is an integer literal it is always safe to replace the reference. In
1236 addition, if the reference appears in the generated code for an object
1237 declaration it is necessary to copy because otherwise the reference
1238 might be to the uninitilized value of the discriminant of the object
1239 itself.
1240
12412011-08-03 Pascal Obry <obry@adacore.com>
1242
1243 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
1244 ACL used, in this case we want to check for ending .exe, not .exe
1245 anywhere in the path.
1246
12472011-08-03 Sergey Rybin <rybin@adacore.com>
1248
1249 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
1250 the tree structure (semantic decoration of references to record
1251 discriminants).
1252
c0b11850
AC
12532011-08-03 Gary Dismukes <dismukes@adacore.com>
1254
1255 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
1256 choices of a named array aggregate, bail out when any choices are
1257 marked as Errors_Posted.
1258
12592011-08-03 Ed Schonberg <schonberg@adacore.com>
1260
1261 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
1262 in which entity is frozen, to handle properly loop variables in
1263 iterators.
1264
12652011-08-03 Ed Schonberg <schonberg@adacore.com>
1266
1267 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
1268 subtype is not static, compute the upper bound using attributes, to
1269 handle properly index types that are not integer types.
1270
12712011-08-03 Bob Duff <duff@adacore.com>
1272
1273 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
1274 Update copyright notice.
1275
12762011-08-03 Ed Schonberg <schonberg@adacore.com>
1277
1278 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
1279 Original_Discriminant if within an instance.
1280 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
1281
12822011-08-03 Thomas Quinot <quinot@adacore.com>
1283
1284 * einfo.ads: Minor reformatting.
1285
12862011-08-03 Ed Schonberg <schonberg@adacore.com>
1287
1288 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
1289 composite type with an unfrozen subcomponent, in the profile of a
1290 primitive operation.
1291
5c34e9cd
AC
12922011-08-03 Robert Dewar <dewar@adacore.com>
1293
1294 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
1295
12962011-08-03 Ed Schonberg <schonberg@adacore.com>
1297
1298 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
1299 unconstrained type with discriminants is initialized with an aggregate,
1300 use the constrained subtype of the aggregate as the type of the object,
1301 because it is immutable, and this allows the back-end to generate no
1302 code for the object declaration.
1303
abcd9db2
AC
13042011-08-03 Robert Dewar <dewar@adacore.com>
1305
1306 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
1307 comparison operand is variable, and turns out to be zero or negative.
1308
13092011-08-03 Javier Miranda <miranda@adacore.com>
1310
1311 * exp_intr.adb
1312 (Expand_Dispatching_Constructor_Call): Disable expansion of
1313 code required for native targets. Done to avoid generating
1314 references to unavailable runtime entities in VM targets.
1315 * exp_ch3.adb
1316 (Expand_N_Object_Declaration): Add missing support to handle
1317 the explicit initialization of class-wide interface objects.
1318 Fix documentation.
1319
13202011-08-03 Matthew Heaney <heaney@adacore.com>
1321
1322 * a-cobove.adb (Merge): Move source onto target, instead of using Assign
1323
13242011-08-03 Matthew Heaney <heaney@adacore.com>
1325
1326 * a-cbdlli.adb (Splice): move source items from first to last
1327
13282011-08-03 Yannick Moy <moy@adacore.com>
1329
1330 * sem_util.ads: comment added.
1331
13322011-08-03 Javier Miranda <miranda@adacore.com>
1333
1334 * exp_aggr.adb
1335 (Expand_Record_Aggregate): In VM targets disable the expansion into
1336 assignments of aggregates whose type is not known at compile time.
1337
b474d6c3
ES
13382011-08-03 Ed Schonberg <schonberg@adacore.com>
1339
1340 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
1341 protected entries and task entries, to build the proper renaming
1342 declaration for entry formals, used in debugging.
1343 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
1344 parameters in the same way.
1345
0580d807
AC
13462011-08-02 Robert Dewar <dewar@adacore.com>
1347
1348 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
1349 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
1350 code reorganization.
1351
13522011-08-02 Robert Dewar <dewar@adacore.com>
1353
1354 * debug.adb: Debug flag d.P to suppress length comparison optimization
1355 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
1356 comparison of Length by comparing First/Last instead.
1357
13582011-08-02 Matthew Heaney <heaney@adacore.com>
1359
1360 * a-cobove.ads: Code clean up.
1361
b191a125
AC
13622011-08-02 Vincent Celier <celier@adacore.com>
1363
1364 * adaint.c (file_names_case_sensitive_cache): New static int.
1365 (__gnat_get_file_names_case_sensitive): Cache the return value in
1366 file_names_case_sensitive_cache at the first invocation, to avoid
1367 multiple calls to getenv.
1368
13692011-08-02 Bob Duff <duff@adacore.com>
1370
1371 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
1372
316a0661
AC
13732011-08-02 Yannick Moy <moy@adacore.com>
1374
1375 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
1376 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
1377 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
1378 indicate that we are in a precondition or postcondition. This is used in
1379 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
1380 decide whether to flag the spec or body of the current subprogram as
1381 not in ALFA.
1382
13832011-08-02 Fabien Chouteau <chouteau@adacore.com>
1384
1385 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
1386 list.
1387 * a-extiin.ads: New file.
1388
13892011-08-02 Bob Duff <duff@adacore.com>
1390
1391 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
1392 now raises Name_Error instead of Use_Error in certain cases. The other
1393 parts of this AI were already implemented properly.
1394
f9adb9d4
AC
13952011-08-02 Vincent Celier <celier@adacore.com>
1396
1397 * link.c: Only import "auto-host.h" when building the gnattools.
1398
13992011-08-02 Yannick Moy <moy@adacore.com>
1400
1401 * sem_util.adb: Inter-unit inlining does not work for a subprogram
1402 which calls a local subprogram, so extract subprogram
1403 from Mark_Non_ALFA_Subprogram_Body.
1404
14052011-08-02 Javier Miranda <miranda@adacore.com>
1406
1407 * exp_ch9.adb
1408 (Extract_Dispatching_Call): If the type of the dispatching object is an
1409 access type then return an explicit dereference in the Object out-mode
1410 parameter.
1411
14122011-08-02 Gary Dismukes <dismukes@adacore.com>
1413
1414 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
1415 compatibility checks for all indexes of an array subtype, not just the
1416 first. Reset Has_Dynamic_Range_Check on the subtype before each
1417 potential check to ensure that Insert_Range_Checks will not elide any
1418 of the dynamic checks.
1419
14202011-08-02 Yannick Moy <moy@adacore.com>
1421
1422 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
1423 SPARK restriction at parsing time.
1424 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
1425 directive only if the SPARK restriction is set for this unit.
1426
83f33150
YM
14272011-08-02 Yannick Moy <moy@adacore.com>
1428
1429 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
1430 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
1431 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
1432 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
1433 Mark_Non_ALFA_Subprogram_Body.
1434 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
1435 inlined.
1436
7b98672f
YM
14372011-08-02 Yannick Moy <moy@adacore.com>
1438
1439 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
1440 might be costly.
1441
052e0603
AC
14422011-08-02 Robert Dewar <dewar@adacore.com>
1443
1444 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
1445 exp_ch3.adb: Minor reformatting.
1446
14472011-08-02 Emmanuel Briot <briot@adacore.com>
1448
1449 * adaint.c (__gnat_locate_exec_on_path): only returns executable
1450 files, not any regular file.
1451 (__gnat_locate_file_with_predicate): new subprogram.
1452
14532011-08-02 Yannick Moy <moy@adacore.com>
1454
1455 * sinfo.adb, sinfo.ads: Restrict the use of flags
1456 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
1457 nodes, plus N_Subtype_Declaration for the 2nd one.
1458
4fbad0ba
AC
14592011-08-02 Sergey Rybin <rybin@adacore.com>
1460
1461 * gnat_rm.texi: Ramification of pragma Eliminate documentation
1462 - fix bugs in the description of Source_Trace;
1463 - get rid of UNIT_NAME;
1464
052e0603
AC
14652011-08-02 Javier Miranda <miranda@adacore.com>
1466
1467 * exp_ch9.adb
1468 (Build_Dispatching_Requeue): Adding support for VM targets
1469 since we cannot directly reference the Tag entity.
1470 * exp_sel.adb (Build_K): Adding support for VM targets.
1471 (Build_S_Assignment): Adding support for VM targets.
1472 * exp_disp.adb
1473 (Default_Prim_Op_Position): In VM targets do not restrict availability
1474 of predefined interface primitives to compiling in Ada 2005 mode.
1475 (Is_Predefined_Interface_Primitive): In VM targets this service is not
1476 restricted to compiling in Ada 2005 mode.
1477 (Make_VM_TSD): Generate code that declares and initializes the OSD
1478 record. Needed to support dispatching calls through synchronized
1479 interfaces.
1480 * exp_ch3.adb
1481 (Make_Predefined_Primitive_Specs): Enable generation of predefined
1482 primitives associated with synchronized interfaces.
1483 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
1484 primitives associated with synchronized interfaces.
1485
14862011-08-02 Yannick Moy <moy@adacore.com>
1487
1488 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
1489 statements hidden in SPARK if preceded by the HIDE directive
1490 (Parse_Exception_Handlers): mark each exception handler in a sequence of
1491 exception handlers as hidden in SPARK if preceded by the HIDE directive
1492 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
1493 if starting with the HIDE directive
1494 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
1495 starting with the HIDE directive; mark the declarations in a private
1496 part as hidden in SPARK if the private part starts with the HIDE
1497 directive
1498 * restrict.adb, restrict.ads
1499 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
1500 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
1501 argument node belongs to a part which is hidden in SPARK
1502 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
1503 parts in SPARK; protect the possibly costly call to
1504 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
1505 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
1506 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
1507 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
1508 Tok_SPARK_Hide.
1509 (Scan): recognize special comment starting with '#' and followed by
1510 SPARK keyword "hide" as a HIDE directive.
1511
15122011-08-02 Yannick Moy <moy@adacore.com>
1513
1514 * types.ads, erroutc.ads: Minor reformatting.
1515
15162011-08-02 Vincent Celier <celier@adacore.com>
1517
1518 * link.c: Add response file support for cross platforms.
1519
15202011-08-02 Ed Schonberg <schonberg@adacore.com>
1521
1522 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
1523 in an association, set parent field of copy before partial analysis.
1524 * sem_res.adb (Resolve_Slice): create reference to itype only when
1525 expansion is enabled.
1526
15272011-08-02 Yannick Moy <moy@adacore.com>
1528
1529 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
1530 for new flag denoting which subprogram bodies are in ALFA
1531 * restrict.adb, sem_ch7.adb: Update comment
1532 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
1533 sem_ch9.adb, sem_res.adb: Add calls to
1534 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
1535 * sem_ch6.adb (Analyze_Function_Return): add calls to
1536 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
1537 middle of the body, and extended return.
1538 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
1539 False when missing return.
1540 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
1541 to True for subprograms whose spec is in ALFA. Remove later on the flag
1542 on the entity used for a subprogram body when there exists a separate
1543 declaration.
1544 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
1545 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
1546 False, otherwise do nothing.
1547
15482011-08-02 Robert Dewar <dewar@adacore.com>
1549
1550 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
1551
15522011-08-02 Yannick Moy <moy@adacore.com>
1553
1554 * sem_ch4.ads: minor formatting.
1555
15562011-08-02 Yannick Moy <moy@adacore.com>
1557
1558 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
1559 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
1560 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
1561 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
1562 opt.ads: cleanup of SPARK mode
1563
15642011-08-02 Yannick Moy <moy@adacore.com>
1565
1566 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
1567 types.
1568 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
1569 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
1570 * sem_ch3.adb
1571 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
1572 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
1573 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
1574 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
1575 types.
1576 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
1577 non-static range.
1578 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
1579 functions whose return type is not in ALFA.
1580 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
1581 specifications.
1582 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
1583 parameter's type is not in ALFA.
1584 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
1585 types are in ALFA.
1586
15872011-08-02 Ed Schonberg <schonberg@adacore.com>
1588
1589 * sem_ch6 (Analyze_Expression_Function): treat the function as
1590 Inline_Always, and introduce a subprogram declaration for it when it is
1591 not a completion.
1592 * inline.adb (Add_Inlined_Body): recognize bodies that come from
1593 expression functions, so that the back-end can determine whether they
1594 can in fact be inlined.
1595 * sem_util.adb (Is_Expression_Function): predicate to determine whether
1596 a function body comes from an expression function.
1597
15982011-08-02 Gary Dismukes <dismukes@adacore.com>
1599
1600 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
1601 null exclusions to test Can_Never_Be_Null on the anonymous access types
1602 of the formals rather than testing the formals themselves. Exclude this
1603 check in cases where the Old_Formal is marked as a controlling formal,
1604 to avoid issuing spurious errors for bodies completing dispatching
1605 operations (due to the flag not getting set on controlling access
1606 formals in body specs).
1607 (Find_Corresponding_Spec): When checking full and subtype conformance of
1608 subprogram bodies in instances, pass Designated and E in that order, for
1609 consistency with the expected order of the formals (New_Id followed by
1610 Old_Id).
1611
16122011-08-02 Robert Dewar <dewar@adacore.com>
1613
1614 * sem_ch8.adb: Minor reformatting.
1615
16162011-08-02 Ed Schonberg <schonberg@adacore.com>
1617
1618 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
1619 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
1620 primitive operations of class-wide actuals.
1621
16222011-08-02 Javier Miranda <miranda@adacore.com>
1623
1624 * exp_atag.ads, exp_atag.adb
1625 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
1626 since its value is implicitly passed in argument Typ.
1627 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
1628 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
1629 Build_Common_Dispatching_Select_Statements.
1630
16312011-08-02 Robert Dewar <dewar@adacore.com>
1632
1633 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
1634 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
1635 Minor reformatting.
1636
16372011-08-02 Robert Dewar <dewar@adacore.com>
1638
1639 * sem_res.adb: Minor reformatting.
1640 * sem_prag.adb: Minor reformatting.
1641
16422011-08-02 Javier Miranda <miranda@adacore.com>
1643
1644 * exp_atag.adb, exp_atags.ads
1645 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
1646 by the tagged type Entity. Required to use this routine in the VM
1647 targets since we do not have available the Tag entity in the VM
1648 platforms.
1649 * exp_ch6.adb
1650 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
1651 Ada.Tags has not been previously loaded.
1652 * exp_ch7.adb
1653 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
1654 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
1655 * sem_aux.adb
1656 (Enclosing_Dynamic_Scope): Add missing support to handle the full
1657 view of enclosing scopes. Required to handle enclosing scopes that
1658 are synchronized types whose full view is a task type.
1659 * exp_disp.adb
1660 (Build_VM_TSDs): Minor code improvement to avoid generating and
1661 analyzing lists with empty nodes.
1662 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
1663 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
1664 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
1665 (Make_Disp_Timed_Select_Body): Add support for VM targets.
1666 (Make_Select_Specific_Data_Table): Add support for VM targets.
1667 (Make_VM_TSD): Generate code to initialize the SSD structure of
1668 the TSD.
1669
16702011-08-02 Yannick Moy <moy@adacore.com>
1671
1672 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
1673 cross-references section in ALI.
1674 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
1675 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
1676 Sub).
1677 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
1678 subprogram or package entity of a node
1679 (Is_Local_Reference_Type): new function returns True for references
1680 selected in local cross-references.
1681 (Lt): function extracted from Lt in Output_References
1682 (Write_Entity_Name): function extracted from Output_References
1683 (Generate_Definition): generate reference with type 'D' for definition
1684 of objects (object declaration and parameter specification), with
1685 appropriate locations and units, for use in local cross-references.
1686 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
1687 references of type 'I' for initialization in object definition.
1688 (Output_References): move part of function Lt and procedure
1689 Write_Entity_Name outside of the body. Ignore references of types 'D'
1690 and 'I' introduced for local cross-references.
1691 (Output_Local_References): new procedure to output the local
1692 cross-references sections.
1693 (Lref_Entity_Status): new array defining whether an entity is a local
1694 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
1695 with 'I' type when initialization expression is present.
1696 * get_scos.adb, get_scos.ads: Correct comments and typos
1697
16982011-08-02 Javier Miranda <miranda@adacore.com>
1699
1700 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
1701 the JVM target.
1702 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
1703 the JVM target.
1704 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
1705 TSD support.
1706
17072011-08-02 Vincent Celier <celier@adacore.com>
1708
1709 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
1710 (No_Space_Img): New function
1711 (Find_Excluded_Sources): When reading from a file, record the file name
1712 and the line number for each excluded source.
1713 (Mark_Excluded_Sources): When reporting an error, if the excluded
1714 sources were read from a file, include file name and line number in
1715 the error message.
1716
17172011-08-02 Ed Schonberg <schonberg@adacore.com>
1718
1719 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
1720
17212011-08-02 Robert Dewar <dewar@adacore.com>
1722
1723 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
1724
17252011-08-02 Javier Miranda <miranda@adacore.com>
1726
1727 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
1728 generation of TSDs to the DOTNET compiler.
1729 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
1730 generation of TSDs to the DOTNET compiler.
1731
17322011-08-02 Javier Miranda <miranda@adacore.com>
1733
1734 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
1735 record of all the tagged types declared inside library level package
1736 declarations, library level package bodies or library level subprograms.
1737 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
1738 associated with a given tagged type.
1739 (Build_VM_TSDs): New subprogram.
1740 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
1741 compilation units that are subprograms.
1742 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
1743 compilation units that are package bodies.
1744 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
1745 units that are a package declaration or a package instantiation.
1746 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
1747 reorganization to improve the error generated by the frontend when the
1748 function Ada.Tags.Secondary_Tag is not available.
1749 * rtsfind.ads (RE_Register_TSD): New runtime entity.
1750 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
1751
17522011-08-02 Javier Miranda <miranda@adacore.com>
1753
1754 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
1755
17562011-08-02 Robert Dewar <dewar@adacore.com>
1757
1758 * s-imenne.ads: Minor reformatting.
1759
17602011-08-02 Robert Dewar <dewar@adacore.com>
1761
1762 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
1763 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
1764 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
1765
17662011-08-02 Robert Dewar <dewar@adacore.com>
1767
1768 * einfo.ads (Materialize_Entity): Document this is only for renamings
1769 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
1770 required debug information in the case where we transform the object
1771 declaration into a renaming declaration.
1772 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
1773 object
1774 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
1775 Materialize_Entity.
1776
17772011-08-02 Robert Dewar <dewar@adacore.com>
1778
1779 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
1780 Suppress_Init_Procs.
1781 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
1782 Suppress_Initialization/Initialization_Suppressed.
1783 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
1784 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
1785 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
1786 * sem_prag.adb: New processing for pragma Suppress_Initialization.
1787
17882011-08-02 Robert Dewar <dewar@adacore.com>
1789
1790 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
1791 Minor reformatting.
1792
17932011-08-02 Ed Schonberg <schonberg@adacore.com>
1794
1795 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
1796 only have inheritable classwide pre/postconditions.
1797
17982011-08-02 Javier Miranda <miranda@adacore.com>
1799
1800 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
1801 * rtsfind.ads (RE_Check_TSD): New runtime entity.
1802 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
1803 checks if the external tag of a type is the same as the external tag
1804 of some other declaration.
1805
18062011-08-02 Thomas Quinot <quinot@adacore.com>
1807
1808 * s-taskin.ads: Minor reformatting.
1809
18102011-08-02 Emmanuel Briot <briot@adacore.com>
1811
1812 * g-comlin.adb (Display_Help): swap the order in which it prints the
1813 short help and the general usage.
1814
18152011-08-02 Ed Schonberg <schonberg@adacore.com>
1816
1817 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
1818 the aspect declarations and attach them to the generic copy for
1819 subsequent analysis.
1820 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
1821 declarations of the generic tree to the new subprogram declarations.
1822 * sem_attr.adb (Check_Precondition_Postcondition): recognize
1823 conditions that apply to a subprogram instance.
1824
18252011-08-02 Robert Dewar <dewar@adacore.com>
1826
1827 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
1828
18292011-08-02 Ed Schonberg <schonberg@adacore.com>
1830
1831 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
1832 private type with a tagged full view is not derived in the immediate
1833 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
1834
18352011-08-02 Robert Dewar <dewar@adacore.com>
1836
1837 * exp_ch4.adb: Minor reformatting.
1838
18392011-08-02 Ed Schonberg <schonberg@adacore.com>
1840
1841 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
1842 Ada2012 iterator, the loop will be rewritten during expansion into a
1843 while loop with a cursor and an element declaration. Do not analyze the
1844 body in this case, because if the container is for indefinite types the
1845 actual subtype of the elements will only be determined when the cursor
1846 declaration is analyzed.
1847
18482011-08-02 Arnaud Charlet <charlet@adacore.com>
1849
1850 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
1851 size/alignment related attributes in CodePeer_Mode.
1852
18532011-08-02 Gary Dismukes <dismukes@adacore.com>
1854
1855 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
1856 Prepend_Element, since this can result in the operation getting the
1857 wrong slot in the full type's dispatch table if the full type has
1858 inherited operations. The incomplete type's operation will get added
1859 to the proper position in the full type's primitives
1860 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
1861 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
1862 dispatching operations, since there are cases where nonprimitive
1863 subprograms can get added to the list of incomplete dependents (such
1864 as subprograms in nested packages).
1865 * sem_ch6.adb (Process_Formals): First, remove test for being in a
1866 private part when determining whether to add a primitive with a
1867 parameter of a tagged incomplete type to the Private_Dependents list.
1868 Such primitives can also occur in the visible part, and should not have
1869 been excluded from being private dependents.
1870 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
1871 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
1872 list of a Taft-amendment incomplete type is a primitive before issuing
1873 an error that the full type must appear in the same unit. There are
1874 cases where nonprimitives can be in the list (such as subprograms in
1875 nested packages).
1876 * sem_disp.adb (Derives_From): Use correct condition for checking that
1877 a formal's type is derived from the type of the corresponding formal in
1878 the parent subprogram (the condition was completely wrong). Add
1879 checking that was missing for controlling result types being derived
1880 from the result type of the parent operation.
1881
18822011-08-02 Yannick Moy <moy@adacore.com>
1883
1884 * errout.adb (First_Node): minor renaming
1885 * restrict.adb (Check_Formal_Restriction): put restriction warning on
1886 first node.
1887
18882011-08-02 Yannick Moy <moy@adacore.com>
1889
1890 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
1891 before accessing operands.
1892 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
1893 decide whether an initialization expression respects SPARK rules, as
1894 the plain node is the expanded one. This allows for more valid warnings
1895 to be issued.
1896 * gnat_rm.texi: Minor update.
1897
18982011-08-02 Arnaud Charlet <charlet@adacore.com>
1899
1900 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
1901 previous change.
1902
19032011-08-02 Robert Dewar <dewar@adacore.com>
1904
1905 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
1906
19072011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1908
1909 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
1910 loop statements and the element renaming declaration with a block when
1911 the element type is controlled.
1912
19132011-08-02 Yannick Moy <moy@adacore.com>
1914
1915 * sinfo.ads: Minor formatting.
1916
19172011-08-02 Ed Schonberg <schonberg@adacore.com>
1918
1919 * sem_aggr.adb (Add_Association): if the association has a box and no
1920 expression, use the Sloc of the aggregate itself for the new
1921 association.
1922 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
1923 the Original_Node.
1924
19252011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1926
1927 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
1928 When a container is provided via a function call, generate a renaming
1929 of the function result. This avoids the creation of a transient scope
1930 and the premature finalization of the container.
1931 * exp_ch7.adb (Is_Container_Cursor): Removed.
1932 (Wrap_Transient_Declaration): Remove the supression of the finalization
1933 of the list controller when the declaration denotes a container cursor,
1934 it is not needed.
1935
19362011-08-02 Yannick Moy <moy@adacore.com>
1937
1938 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
1939 node is from source, instead of the original node being from source.
1940 * sem_aggr.adb
1941 (Resolve_Array_Aggregate): refine the check for a static expression, to
1942 recognize also static ranges
1943 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
1944 Array_Type_Declaration): postpone the test for the type being a subtype
1945 mark after the type has been resolved, so that component-selection and
1946 expanded-name are discriminated.
1947 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
1948 to distinguish the case of an iteration scheme, so that an error is
1949 issed on a non-static range in SPARK except in an iteration scheme.
1950 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
1951 In_Iter_Schm = True.
1952 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
1953 user-defined operators so that they are allowed in renaming
1954 * sem_ch8.adb
1955 (Find_Selected_Component): refine the check for prefixing of operators
1956 so that they are allowed in renaming. Move the checks for restrictions
1957 on selector name after analysis discriminated between
1958 component-selection and expanded-name.
1959 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
1960 concatenation argument of string type if it is static.
1961 * sem_util.adb, sem_util.ads
1962 (Check_Later_Vs_Basic_Declarations): add a new function
1963 Is_Later_Declarative_Item to decice which declarations are allowed as
1964 later items, in the two different modes Ada 83 and SPARK. In the SPARK
1965 mode, add that renamings are considered as later items.
1966 (Enclosing_Package): new function to return the enclosing package
1967 (Enter_Name): correct the rule for homonyms in SPARK
1968 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
1969 from source (result of expansion) to avoid issuing wrong warnings.
1970
19712011-08-02 Ed Schonberg <schonberg@adacore.com>
1972
1973 * errout.adb: On anything but an expression First_Node returns its
1974 argument.
1975
19762011-08-02 Pascal Obry <obry@adacore.com>
1977
1978 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
1979
19802011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1981
1982 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
1983 Set the associated loop as the related expression of internally
1984 generated cursors.
1985 * exp_ch7.adb (Is_Container_Cursor): New routine.
1986 (Wrap_Transient_Declaration): Supress the finalization of the list
1987 controller when the declaration denotes a container cursor.
1988
19892011-08-02 Yannick Moy <moy@adacore.com>
1990
1991 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
1992 command line now.
1993 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
1994 expression is a simple expression. This check cannot be performed in
1995 the semantics, so just drop it.
1996 (P_Index_Or_Discriminant_Constraint): move check that the index or
1997 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
1998 semantics. Other cases were previously checked in the semantics.
1999 * par-ch4.adb (P_Name): move checks that a selector name is not
2000 character literal or an operator symbol to Find_Selected_Component in
2001 the semantics
2002 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
2003 declarations are not placed after later declarations in a separate
2004 procedure in Sem_Util (possibly not the best choice?), to be used both
2005 during parsing, for Ada 83 mode, and during semantic analysis, for
2006 SPARK mode.
2007 * par-endh.adb (Check_End): move check that end label is not missing
2008 to Process_End_Label in the semantics
2009 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
2010 the special case for SPARK restriction
2011 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
2012 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
2013 parameter Force to issue the error message even on internal node (used
2014 for generated end label). Call Check_Restriction to check when an error
2015 must be issued. In SPARK mode, issue an error message even if the
2016 restriction is not set.
2017 (Check_Restriction): new procedure with an additional out parameter to
2018 inform the caller that a message has been issued
2019 * sem_aggr.adb: Minor modification of message
2020 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
2021 instead of issuing an error message directly
2022 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
2023 declarations are not placed after later declarations, by calling
2024 Check_Later_Vs_Basic_Declarations
2025 (Analyze_Subtype_Declaration): move here the check that an index or
2026 discriminant constraint must be a subtype mark. Change the check that
2027 a subtype of String must start at one so that it works on subtype marks.
2028 * sem_ch4.adb (Analyze_Call): move here the check that a named
2029 association cannot follow a positional one in a call
2030 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
2031 instead of issuing an error message directly
2032 * sem_ch8.adb (Find_Selected_Component): move here the check that a
2033 selector name is not a character literal or an operator symbol. Move
2034 here the check that the prefix of an expanded name cannot be a
2035 subprogram or a loop statement.
2036 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
2037 procedure called from parsing and semantics to check that basic
2038 declarations are not placed after later declarations
2039 (Process_End_Label): move here the check that end label is not missing
2040
20412011-08-02 Arnaud Charlet <charlet@adacore.com>
2042
2043 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
2044 representation clause in codepeer mode, since it confuses CodePeer and
2045 does not bring useful info.
2046
20472011-08-02 Ed Falis <falis@adacore.com>
2048
2049 * init.c: initialize fp hw on MILS.
2050
20512011-08-02 Ed Schonberg <schonberg@adacore.com>
2052
2053 * errout.adb (First_Node): for bodies, return the node itself (small
2054 optimization). For other nodes, do not check source_unit if the node
2055 comes from Standard.
2056
20572011-08-02 Robert Dewar <dewar@adacore.com>
2058
2059 * exp_ch3.adb: Minor comment additions.
2060 * sem_ch13.adb: Minor reformatting.
2061
20622011-08-02 Pascal Obry <obry@adacore.com>
2063
2064 * make.adb, makeutl.adb: Removes some superfluous directory separator.
2065
20662011-08-02 Robert Dewar <dewar@adacore.com>
2067
2068 * sem_attr.adb: Minor reformatting.
2069
20702011-08-02 Robert Dewar <dewar@adacore.com>
2071
2072 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
2073 (Has_Default_Component_Value): Removed
2074 * einfo.ads Comment updates
2075 (Has_Default_Aspect): Replaces Has_Default_Value
2076 (Has_Default_Component_Value): Removed
2077 * exp_ch13.adb
2078 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
2079 * exp_ch3.adb
2080 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
2081 (Get_Simple_Init_Val): Handle Default_Value aspect
2082 (Needs_Simple_Initialization): Handle Default_Value aspect
2083 * exp_ch3.ads: Needs_Simple_Initialization
2084 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
2085 * par-prag.adb (Pragma_Default[_Component]Value) Removed
2086 * sem_ch13.adb
2087 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
2088 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
2089 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
2090
20912011-08-02 Ed Schonberg <schonberg@adacore.com>
2092
2093 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
2094 package containing iteration primitives.
2095 exp_ch5.adb (Expand_Iterator_Loop): ditto.
2096
20972011-08-02 Ed Schonberg <schonberg@adacore.com>
2098
2099 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
2100 "of", pre-analyze expression in case it is a function call with
2101 finalization actions that must be placed ahead of the loop.
2102 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
2103 on an Ada2012 iterator, insert them ahead of the rewritten loop.
2104
21052011-08-02 Geert Bosch <bosch@adacore.com>
2106
2107 * cstand.adb (Create_Float_Types): Only consider C's long double for
2108 Long_Long_Float, in addition to double.
2109
21102011-08-02 Robert Dewar <dewar@adacore.com>
2111
2112 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
2113 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
2114 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
2115 Minor reformatting.
2116
21172011-08-02 Ed Schonberg <schonberg@adacore.com>
2118
2119 * sem_attr.adb: handle properly 'Result when it is a prefix of an
2120 indexed component.
2121
21222011-08-02 Javier Miranda <miranda@adacore.com>
2123
2124 * einfo.ads, einfo.adb
2125 (Original_Access_Type): Move this attribute to Node26 since there was
2126 an undocumented use of Node21 in E_Access_Subprogram_Type entities
2127 which causes conflicts and breaks the generation of the .NET compiler.
2128 (Interface_Name): Add missing documentation on JGNAT only uses of
2129 this attribute.
2130
21312011-08-02 Geert Bosch <bosch@adacore.com>
2132
2133 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
2134 (Find_Back_End_Float_Type): Likewise
2135 (Create_Back_End_Float_Types): Likewise
2136 (Create_Float_Types): Likewise
2137 (Register_Float_Type): Likewise
2138 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
2139 Nlist and split out type selection in new local Find_Base_Type function.
2140 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
2141 Nlist
2142 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
2143
21442011-08-02 Robert Dewar <dewar@adacore.com>
2145
2146 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
2147 alpha order).
2148 * opt.ads: Minor comment change.
2149 * sem_ch12.adb: Minor code reorganization.
2150
21512011-08-02 Gary Dismukes <dismukes@adacore.com>
2152
2153 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
2154 subtype's list of rep items to the list on the full subtype in the case
2155 where the lists are the same.
2156
21572011-08-02 Geert Bosch <bosch@adacore.com>
2158
2159 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
2160 using the one from System.Strings, which also deallocates all strings.
2161
21622011-08-02 Geert Bosch <bosch@adacore.com>
2163
2164 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
2165 function.
2166 * gcc-interface/Make-lang.in: Update dependencies.
2167
21682011-08-02 Olivier Hainque <hainque@adacore.com>
2169
2170 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
2171 end_locus.
2172
21732011-08-02 Javier Miranda <miranda@adacore.com>
2174
2175 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
2176 associated with anonymous access to subprograms.
2177
21782011-08-02 Geert Bosch <bosch@adacore.com>
2179
2180 * opt.ads
2181 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
2182 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
2183 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
2184 (Add_Symbol_Definition): Move to switch-c.adb
2185 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
2186 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
2187 (Add_Symbol_Definition): Move to switch-c.adb.
2188 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
2189 * sem_warn.adb
2190 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
2191 Move to warnsw.adb.
2192 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
2193 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
2194 Move to warnsw.adb.
2195 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
2196 (Add_Symbol_Definition): Moved from Prepcomp.
2197 * switch-c.ads: Update copyright notice. Use String_List instead of
2198 Argument_List, removing dependency on System.OS_Lib.
2199
22002011-08-02 Yannick Moy <moy@adacore.com>
2201
2202 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
2203 mode on initialization expression which does not respect SPARK
2204 restrictions.
2205 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
2206 if the tree referenced by its argument represents an initialization
2207 expression in SPARK, suitable for initializing an object in an object
2208 declaration.
2209
22102011-08-02 Javier Miranda <miranda@adacore.com>
2211
2212 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
2213 internally generated access to subprogram with its associated protected
2214 subprogram type.
2215 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
2216
22172011-08-02 Geert Bosch <bosch@adacore.com>
2218
2219 * cstand.adb (Register_Float_Type): Print information about type to
2220 register, if the Debug_Flag_Dot_B is set.
2221 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
2222 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
2223 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
2224 with a requested precision of more than Max_Digits digits and no more
2225 than Max_Base_Digits digits, if a range specification is present and the
2226 Predefined_Float_Types list has a suitable type to derive from.
2227 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
2228 case of type completion with pragma Import
2229 * sem_prag.adb
2230 (Process_Import_Predefined_Type): Processing to complete a type
2231 with pragma Import. Currently supports floating point types only.
2232 (Set_Convention_From_Pragma): Do nothing without underlying type.
2233 (Process_Convention): Guard against absence of underlying type,
2234 which may happen when importing incomplete types.
2235 (Process_Import_Or_Interface): Handle case of importing predefined
2236 types. Tweak error message.
2237
22382011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2239
2240 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
2241 functions to previous change. Reorganize code slightly.
2242
22432011-08-02 Geert Bosch <bosch@adacore.com>
2244
2245 * back_end.ads (Register_Type_Proc): New call back procedure type for
2246 allowing the back end to provide information about available types.
2247 (Register_Back_End_Types): New procedure to register back end types.
2248 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
2249 available types.
2250 * cstand.adb (Back_End_Float_Types): New list for floating point types
2251 supported by the back end.
2252 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
2253 (Copy_Float_Type): New procedure to make new copies of predefined types.
2254 (Register_Float_Type): New call back procedure to populate the BEFT list
2255 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
2256 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
2257 (Create_Float_Types): New procedure to create entities for floating
2258 point types predefined in Standard, and put these and any remaining
2259 BEFTs on the Predefined_Float_Types list.
2260 * stand.ads (Predefined_Float_Types): New list for predefined floating
2261 point types that do not have declarations in package Standard.
2262
22632011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2264
2265 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
2266 entity node for the unit containing the parameter.
2267 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
2268 (Add_Inlined_Subprogram): Likewise.
2269 * gcc-interface/Make-lang.in: Update dependencies.
2270
22712011-08-02 Thomas Quinot <quinot@adacore.com>
2272
2273 * s-stusta.adb (Print): Make sure Pos is always initialized to a
2274 suitable value.
2275
22762011-08-02 Geert Bosch <bosch@adacore.com>
2277
2278 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
2279
22802011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2281
2282 * sem_type.adb (Covers): Move trivial case to the top and reuse the
2283 computed value of Base_Type.
2284
22852011-08-02 Yannick Moy <moy@adacore.com>
2286
2287 * restrict.adb (Check_Restriction): issue an error for any use of
2288 class-wide, even if the No_Dispatch restriction is not set.
2289 * sem_aggr.adb: Correct typos in comments and messages in formal mode
2290 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
2291 when completing a private extension, the type named in the private part
2292 is not the same as that named in the visible part.
2293 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
2294 of an inherited primitive operations of a tagged type or type extension
2295 that returns the tagged type.
2296 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
2297 function which returns True for an implicit operation inherited by the
2298 derived type declaration for the argument type.
2299 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
2300 order.
2301
23022011-08-02 Ed Schonberg <schonberg@adacore.com>
2303
2304 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
2305 Process_Bounds, to perform analysis with expansion of a range or an
2306 expression that is the iteration scheme for a loop.
2307 (Analyze_Iterator_Specification): If domain of iteration is given by a
2308 function call with a controlled result, as is the case if call returns
2309 a predefined container, ensure that finalization actions are properly
2310 generated.
2311 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
2312
23132011-08-02 Javier Miranda <miranda@adacore.com>
2314
2315 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
2316 * gcc-interface/Make-lang.in: Update dependencies.
2317
23182011-08-02 Javier Miranda <miranda@adacore.com>
2319
2320 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
2321 determine if the analysis is performed using N or Original_Node (N).
2322 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
2323 functionality of routine Is_Variable avoids code duplication.
2324 * checks.adb (Determine_Range): Handle temporaries generated by
2325 Remove_Side_Effects.
2326
23272011-08-02 Javier Miranda <miranda@adacore.com>
2328
2329 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
2330 expansion of the condition. Required since the previous analysis was
2331 done with expansion disabled (see Resolve_Quantified_Expression) and
2332 hence checks were not inserted and record comparisons have not been
2333 expanded.
2334
23352011-08-02 Ed Falis <falis@adacore.com>
2336
2337 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
2338 Update header.
2339
23402011-08-02 Bob Duff <duff@adacore.com>
2341
2342 * opt.ads: Minor comment fix.
2343
23442011-08-02 Bob Duff <duff@adacore.com>
2345
2346 * sem_ch12.adb (Analyze_Package_Instantiation,
2347 Analyze_Subprogram_Instantiation): Turn off style checking while
2348 analyzing an instance. Whatever style checks that apply to the generic
2349 unit should apply, so it makes no sense to apply them in an instance.
2350 This was causing trouble when compiling an instance of a runtime
2351 unit that violates the -gnatyO switch.
2352 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
2353 one of the two case statements, causing spurious errors.
2354
23552011-08-02 Robert Dewar <dewar@adacore.com>
2356
2357 * uname.adb: Minor reformatting.
2358 * gnatcmd.adb: Minor reformatting.
2359 * exp_attr.adb: Minor reformatting.
2360
23612011-08-02 Ed Schonberg <schonberg@adacore.com>
2362
2363 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
2364 No_Dispatching_Calls, do not look for the Assign primitive, because
2365 predefined primitives are not created in this case.
2366
23672011-08-02 Bob Duff <duff@adacore.com>
2368
2369 * stylesw.ads: Minor comment fixes.
2370
23712011-08-02 Robert Dewar <dewar@adacore.com>
2372
2373 * freeze.adb (Add_To_Result): New procedure.
2374
23752011-08-02 Jose Ruiz <ruiz@adacore.com>
2376
2377 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
2378 time, if the specific run-time routines for handling streams of strings
2379 are not available, use the default mechanism.
2380
23812011-08-02 Arnaud Charlet <charlet@adacore.com>
2382
2383 * s-regpat.ads: Fix typo.
2384
23852011-08-02 Vincent Celier <celier@adacore.com>
2386
2387 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
2388 not null, call it to create the in memory config project file without
2389 parsing an existing default config project file.
2390
23912011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2392
2393 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
2394
23952011-08-02 Ed Schonberg <schonberg@adacore.com>
2396
2397 * sem_elim.adb: an abstract subprogram does not need an eliminate
2398 pragma for its descendant to be eliminable.
2399
24002011-08-02 Ed Falis <falis@adacore.com>
2401
2402 * init.c: revert to handling before previous checkin for VxWorks
2403 * s-intman-vxworks.adb: delete unnecessary declarations related to
2404 using Ada interrupt facilities for handling signals.
2405 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
2406 * s-intman-vxworks.ads: Import __gnat_install_handler as
2407 Initialize_Interrupts.
2408 * s-taprop-vxworks.adb: Delete Signal_Mask.
2409 (Abort_Handler): change construction of mask to unblock exception
2410 signals.
2411
24122011-08-02 Jerome Guitton <guitton@adacore.com>
2413
2414 * a-except-2005.adb (Raise_From_Signal_Handler): Call
2415 Debug_Raise_Exception before propagation starts.
2416
24172011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2418
2419 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
2420 to Restriction_Check_Required.
2421 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
2422 * sem_res.adb (Resolve_Call): Likewise.
2423 * sem_attr.adb (Check_Stream_Attribute): Likewise.
2424
24252011-08-02 Bob Duff <duff@adacore.com>
2426
2427 * stylesw.ads: Update comment.
2428 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
2429 * errout.ads: Remove obsolete comment.
2430
24312011-08-02 Javier Miranda <miranda@adacore.com>
2432
2433 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
2434 (Set_Is_Safe_To_Reevaluate): new procedure.
2435 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
2436 assignment is allowed on safe-to-reevaluate variables.
2437 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
2438 temporary created to remove side effects in expressions that use
2439 the secondary stack as safe-to-reevaluate.
2440 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
2441 variables that are not true constants.
2442
24432011-08-02 Robert Dewar <dewar@adacore.com>
2444
2445 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
2446 sem_res.adb, sem_ch6.adb: Minor reformatting.
2447
24482011-08-02 Jerome Guitton <guitton@adacore.com>
2449
2450 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
2451
24522011-08-02 Ed Schonberg <schonberg@adacore.com>
2453
2454 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
2455 not set Overridden_Operation if subprogram is an initialization
2456 procedure.
2457
24582011-08-02 Yannick Moy <moy@adacore.com>
2459
2460 * par-ch6.adb: Correct obsolete name in comments
2461 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
2462 which takes two message arguments (existing function takes one), with
2463 second message used for continuation.
2464 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
2465 block statements that originate from a source block statement, not
2466 generated block statements
2467 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
2468 symmetry with procedure case
2469 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
2470 function to issue an error in formal mode if a package specification
2471 contains more than one tagged type or type extension.
2472 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
2473 parameters matching formals of tagged types are objects (or ancestor
2474 type conversions of objects), not general expressions. Issue an error
2475 on view conversions that are not involving ancestor conversion of an
2476 extended type.
2477 (Resolve_Type_Conversion): in formal mode, issue an error on the
2478 operand of an ancestor type conversion which is not an object
2479 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
2480 procedure so that it works also for actuals of function calls
2481 (Is_Actual_Tagged_Parameter): new function which determines if its
2482 argument is an actual parameter of a formal of tagged type in a
2483 subprogram call
2484 (Is_SPARK_Object_Reference): new function which determines if the tree
2485 referenced by its argument represents an object in SPARK
2486
24872011-08-02 Robert Dewar <dewar@adacore.com>
2488
2489 * sem_ch3.adb: Minor reformatting
2490 Minor comment addition
2491 Minor error msg text change
2492
24932011-08-02 Javier Miranda <miranda@adacore.com>
2494
2495 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
2496 function. Used to be more precise when we generate a variable plus one
2497 assignment to remove side effects in the evaluation of the Bound
2498 expressions.
2499 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
2500 of the bound expression to force its re-analysis and thus expand the
2501 associated transient scope (if required). Code cleanup replacing the
2502 previous code that declared the constant entity by an invocation to
2503 routine Force_Evaluation which centralizes this work in the frontend.
2504
25052011-08-02 Robert Dewar <dewar@adacore.com>
2506
2507 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
2508 (Base_Type): Now uses improved Is_Base_Type function
2509 * einfo.ads (Base_Type): Inline this function
2510
25112011-08-02 Robert Dewar <dewar@adacore.com>
2512
2513 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
2514 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
2515
25162011-08-02 Arnaud Charlet <charlet@adacore.com>
2517
2518 * gcc-interface/Make-lang.in: Update dependencies.
2519 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
2520 targets.
2521
25222011-08-02 Yannick Moy <moy@adacore.com>
2523
2524 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
2525 non-simple expression used in delta constraint
2526 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
2527 index constraint which is not a subtype mark
2528 * par.adb: With and use Restrict
2529 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
2530 mode on component type which is not a subtype mark and default
2531 expression on component
2532 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
2533 of string which does not have a lower index bound equal to 1
2534 (Array_Type_Declaration): issue an error in formal mode on index or
2535 component type which is not a subtype mark, and on aliased keyword on
2536 component
2537 (Derived_Type_Declaration): issue an error in formal mode on interface,
2538 limited or abstract type
2539 (Record_Type_Declaration): issue an error in formal mode on interface
2540 (Record_Type_Definition): issue an error in formal mode on tagged types
2541 and type extensions not declared in the specification of a library unit
2542 package; on null non-tagged record; on variant part
2543
25442011-08-02 Vincent Celier <celier@adacore.com>
2545
2546 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
2547 not declared for qualified library project when Library_Name is not
2548 declared, but Library_Dir is.
2549
25502011-08-02 Robert Dewar <dewar@adacore.com>
2551
2552 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
2553 pragmas (affects aspects [Component_]Default_Value
2554 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
2555 component type for the resolution
2556
25572011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2558
2559 * einfo.adb (Base_Type): Tune implementation for speed.
2560
25612011-08-02 Robert Dewar <dewar@adacore.com>
2562
2563 * freeze.adb: Minor reformatting.
2564
25652011-08-02 Thomas Quinot <quinot@adacore.com>
2566
2567 * scos.ads: Update comments.
2568
25692011-08-02 Ed Schonberg <schonberg@adacore.com>
2570
2571 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
2572 base type, because the parent may be a subtype of a private type whose
2573 convention is established in a private part.
2574
25752011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
2576
2577 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
2578 statement in a block when the expansion of the return expression has
2579 created a finalization chain.
2580 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
2581 with the parent node.
2582 Add N_Extended_Return_Statement to handle the case where a transient
2583 object declaration appears in the Return_Object_Declarations list of
2584 an extended return statement.
2585
25862011-08-02 Matthew Gingell <gingell@adacore.com>
2587
2588 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
2589 unused parameter 'name'.
2590
25912011-08-02 Ed Schonberg <schonberg@adacore.com>
2592
2593 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
2594 inherited operation, check whether its alias, which is the source
2595 operastion that it renames, has been marked eliminated.
2596
25972011-08-02 Javier Miranda <miranda@adacore.com>
2598
2599 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
2600 in-mode parameter whose type is an access type since it can be used to
2601 modify its designated object. Enforce code that handles as safe an
2602 access type that is not access-to-constant but it is the result of a
2603 previous removal of side-effects.
2604 (Remove_Side_Effects): Minor code reorganization of cases which require
2605 no action. Done to incorporate documentation on new cases uncovered
2606 working in this ticket: no action needed if this routine was invoked
2607 too early and the nodes are not yet decorated.
2608 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
2609 to routine Remove_Side_Effects by calls to Force_Evaluation since they
2610 were issued with actuals that are implicitly provided by
2611 Force_Evaluation.
2612
26132011-08-02 Robert Dewar <dewar@adacore.com>
2614
2615 * sem_ch3.adb, sem_res.adb: Minor reformatting.
2616
26172011-08-02 Yannick Moy <moy@adacore.com>
2618
2619 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
2620 to issue an error in formal mode on attribute not supported in this mode
2621 (Analyze_Attribute): issue errors on standard attributes not supported
2622 in formal mode.
2623 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
2624 comment, and issue error in formal mode on modulus which is not a power
2625 of 2.
2626 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
2627 range.
2628 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
2629 subtype mark.
2630 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
2631 operator on modular type (except 'not').
2632
26332011-08-02 Robert Dewar <dewar@adacore.com>
2634
2635 * gnat_rm.texi: Minor reformatting.
2636
26372011-08-02 Arnaud Charlet <charlet@adacore.com>
2638
2639 * s-osinte-linux.ads: Minor comment update and reformatting.
2640 * i-cexten.ads: Make this unit pure, as for its parent.
2641 Will allow its usage in more contexts if needed.
2642
26432011-08-02 Robert Dewar <dewar@adacore.com>
2644
2645 * s-utf_32.ads: Minor comment fix.
2646
26472011-08-02 Ed Schonberg <schonberg@adacore.com>
2648
2649 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
2650 operation of a tagged synchronized type, handle the case where the
2651 controlling argument is overloaded.
2652
26532011-08-02 Yannick Moy <moy@adacore.com>
2654
2655 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
2656 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
2657 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
2658 SPARK mode and formal verification mode on processing SPARK restriction
2659 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
2660 requiring consistency checking.
2661
26622011-08-02 Robert Dewar <dewar@adacore.com>
2663
2664 * sem_res.adb: Minor reformatting.
2665
26662011-08-02 Robert Dewar <dewar@adacore.com>
2667
2668 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
2669 a-cforse.ads: Remove unneeded with of Ada.Containers
2670 Remove commented out pragma Inline's
2671 Move specifications of new subprograms to the actual specs
2672
26732011-08-02 Yannick Moy <moy@adacore.com>
2674
2675 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
2676 a-cforse.ads: Update comments.
2677
26782011-08-02 Ed Schonberg <schonberg@adacore.com>
2679
2680 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
2681
26822011-08-02 Robert Dewar <dewar@adacore.com>
2683
2684 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
2685 a-cforse.ads, a-cofove.ads: Minor reformatting.
2686
26872011-08-02 Claire Dross <dross@adacore.com>
2688
2689 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
2690 a-cofove.ads: Add comments.
2691
26922011-08-02 Yannick Moy <moy@adacore.com>
2693
2694 * gnat_rm.texi: Document formal containers.
2695
26962011-08-02 Emmanuel Briot <briot@adacore.com>
2697
2698 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
2699 are empty sections.
2700
27012011-08-02 Robert Dewar <dewar@adacore.com>
2702
2703 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
2704 reformatting.
2705
27062011-08-02 Robert Dewar <dewar@adacore.com>
2707
2708 * aspects.adb: New aspects Default_Value and Default_Component_Value
2709 New format of Aspect_Names table checks for omitted entries
2710 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
2711 handling of boolean aspects for derived types.
2712 New aspects Default_Value and Default_Component_Value
2713 New format of Aspect_Names table checks for omitted entries
2714 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
2715 (Has_Default_Value): New flag
2716 (Has_Default_Component_Value): New flag
2717 (Has_Default_Value): New flag
2718 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
2719 table.
2720 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
2721 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
2722 Default_Value and Default_Component_Value
2723 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
2724 New aspects Default_Value and Default_Component_Value
2725 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
2726 * sprint.adb: Print N_Aspect_Specification node when called from gdb
2727
27282011-08-02 Vincent Celier <celier@adacore.com>
2729
2730 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
2731 inherit library kind.
2732
27332011-08-02 Ed Schonberg <schonberg@adacore.com>
2734
2735 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
2736 Minor reformatting.
2737
27382011-08-02 Robert Dewar <dewar@adacore.com>
2739
2740 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
2741
27422011-08-02 Yannick Moy <moy@adacore.com>
2743
2744 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
2745
27462011-08-02 Robert Dewar <dewar@adacore.com>
2747
2748 * impunit.adb: Add comment.
2749
27502011-08-02 Yannick Moy <moy@adacore.com>
2751
2752 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
2753 qualification of aggregates in formal mode
2754 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
2755 another aggregate
2756 (Resolve_Aggregate): complete the test that an aggregate is adequately
2757 qualified in formal mode
2758
27592011-08-02 Pascal Obry <obry@adacore.com>
2760
2761 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
2762 * mlib-prj.adb: Supress warning when compiling binder generated file.
2763 (Build_Library): Supress all warnings when compiling the binder
2764 generated file.
2765
27662011-08-02 Yannick Moy <moy@adacore.com>
2767
2768 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
2769 from here...
2770 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
2771 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
2772 Add with/use clauses to make Check_Formal_Restriction visible
2773
27742011-08-02 Ed Schonberg <schonberg@adacore.com>
2775
2776 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
2777 in-parameters when type of the generic formal is private in the generic
2778 spec and non-private in the body.
2779
27802011-08-02 Claire Dross <dross@adacore.com>
2781
2782 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
2783 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
2784 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
2785 * impunit.adb, Makefile.rtl: Take new files into account.
2786
27872011-08-02 Robert Dewar <dewar@adacore.com>
2788
2789 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
2790 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
2791
27922011-08-02 Yannick Moy <moy@adacore.com>
2793
2794 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
2795 formal mode
2796 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
2797 matching static array bounds, taking into account the special case of
2798 string literals
2799 * sem_ch3.adb: Typo in comment.
2800
28012011-08-02 Yannick Moy <moy@adacore.com>
2802
2803 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
2804 which issues an error in formal mode if its argument node is originally
2805 from source
2806 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
2807 has a discriminant specification so that it does not include the case
2808 of derived types
2809 (Derived_Type_Declaration): move here the test that a derived type has a
2810 discriminant specification
2811 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
2812 first element of a component association before accessing its choices
2813 (presence of component association is not enough)
2814 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
2815 declaration is a library item before accessing the next element in a
2816 list, as library items are not member of lists
2817 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
2818 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
2819 Check_Formal_Restriction whenever possible.
2820
28212011-08-02 Ed Schonberg <schonberg@adacore.com>
2822
2823 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
2824 reference when needed.
2825
28262011-08-02 Bob Duff <duff@adacore.com>
2827
2828 * gnat_ugn.texi: Fix typo.
2829
28302011-08-02 Vincent Celier <celier@adacore.com>
2831
2832 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
2833 archive file name. Do not use the full path name of archives for Open
2834 VMS.
2835
28362011-08-02 Robert Dewar <dewar@adacore.com>
2837
2838 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
2839 Analyze_Aspect_Specifications
2840 * sem_ch13.adb
2841 (Analyze_Aspect_Specifications): New handling for boolean aspects
2842 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
2843 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
2844 sequence for Analyze_Aspect_Specifications
2845 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
2846 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
2847
28482011-08-02 Robert Dewar <dewar@adacore.com>
2849
2850 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
2851 aspects, since these no longer exist.
2852
28532011-08-02 Robert Dewar <dewar@adacore.com>
2854
2855 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
2856 semicolon, do not try to see if there are aspects following it.
2857 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
2858 aspect spec.
2859
28602011-08-02 Robert Dewar <dewar@adacore.com>
2861
2862 * sem_ch8.adb, aspects.ads: Minor reformatting.
2863
28642011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2865
2866 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
2867 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
2868 extracted from...
2869 (Analyze_Aspect_Specifications): ...here. Call above procedure.
2870
28712011-08-02 Yannick Moy <moy@adacore.com>
2872
2873 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
2874 mode on subprogram declaration outside of package specification, unless
2875 it is followed by a pragma Import
2876 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
2877 Access_Type_Declaration): issue error in formal mode on access type
2878 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
2879 incomplete type
2880 (Analyze_Object_Declaration): issue error in formal mode on object
2881 declaration which does not respect SPARK restrictions
2882 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
2883 declaration which does not respect SPARK restrictions
2884 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
2885 error in formal mode on digits or delta constraint
2886 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
2887 decimal fixed point type
2888 (Derived_Type_Declaration): issue error in formal mode on derived type
2889 other than type extensions of tagged record types
2890 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
2891 with check on access definition
2892 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
2893 mode on protected definition.
2894 (Analyze_Task_Definition): issue error in formal mode on task definition
2895
28962011-08-02 Robert Dewar <dewar@adacore.com>
2897
2898 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
2899
29002011-08-02 Javier Miranda <miranda@adacore.com>
2901
2902 * sem_ch6.adb (Can_Override_Operator): New function.
2903 (Verify_Overriding_Indicator): Add missing code to check overriding
2904 indicator in operators. Fixes regression.
2905 (Check_Overriding_Indicator): Minor reformating after replacing the
2906 code that evaluates if the subprogram can override an operator by
2907 invocations to the above new function.
2908 * einfo.adb
2909 (Write_Field26_Name): Add missing code to ensure that, following
2910 the documentation in einfo.ads, this field is not shown as attribute
2911 "Static_Initialization" on non-dispatching functions.
2912
29132011-08-02 Jose Ruiz <ruiz@adacore.com>
2914
2915 * sem_res.adb (Resolve_Call): A call to
2916 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
2917 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
2918 i.e., when the second parameter is of type Time_Span.
2919
29202011-08-02 Vincent Celier <celier@adacore.com>
2921
2922 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
2923 with an archive instead of -L<library dir> -l<library name>.
2924
29252011-08-02 Ed Schonberg <schonberg@adacore.com>
2926
2927 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
2928 mark the base types In_Use in addition to making the operations
2929 use_visible.
2930
29312011-08-02 Ed Falis <falis@adacore.com>
2932
2933 * init.c: add and setup __gnat_signal_mask for the exception signals
2934 * s-inmaop-vxworks.adb: new file.
2935 * s-intman-vxworks.adb: remove unnecessary initializations and
2936 simplify remaining
2937 * s-intman-vxworks.ads: remove unnecessary variable
2938 * s-taprop-vxworks.adb: simplify signal initialization
2939
29402011-08-02 Robert Dewar <dewar@adacore.com>
2941
2942 * sem_ch8.adb: Minor code reorganization, comment updates.
2943
29442011-08-02 Robert Dewar <dewar@adacore.com>
2945
2946 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
2947 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
2948 here from Sem_Res.
2949 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
2950 (Matching_Static_Array_Bounds): Moved here from Sem_Res
2951
29522011-08-02 Ed Schonberg <schonberg@adacore.com>
2953
2954 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
2955 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
2956 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
2957 use_type_clauses, to handle more efficiently use_type and use_all_type
2958 constructs.
2959 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
2960 Ada2012 Use_All_Type clause.
2961 (Use_Class_Wide_Operations): new procedure.
2962
29632011-08-02 Robert Dewar <dewar@adacore.com>
2964
2965 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
2966 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
2967 expression to expression function.
2968
29692011-08-02 Ed Schonberg <schonberg@adacore.com>
2970
2971 * sem_ch4.adb: transform simple Ada2012 membership into equality only
2972 if types are compatible.
2973
29742011-08-02 Yannick Moy <moy@adacore.com>
2975
2976 * sem_res.adb (Matching_Static_Array_Bounds): new function which
2977 returns True if its argument array types have same dimension and same
2978 static bounds at each index.
2979 (Resolve_Actuals): issue an error in formal mode on actuals passed as
2980 OUT or IN OUT paramaters which are not view conversions in SPARK.
2981 (Resolve_Arithmetic_Op): issue an error in formal mode on
2982 multiplication or division with operands of fixed point types which are
2983 not qualified or explicitly converted.
2984 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
2985 Boolean or array type (except String) operands.
2986 (Resolve_Equality_Op): issue an error in formal mode on equality
2987 operators for array types other than String with non-matching static
2988 bounds.
2989 (Resolve_Logical_Op): issue an error in formal mode on logical operators
2990 for array types with non-matching static bounds. Factorize the code in
2991 Matching_Static_Array_Bounds.
2992 (Resolve_Qualified_Expression): issue an error in formal mode on
2993 qualified expressions for array types with non-matching static bounds.
2994 (Resolve_Type_Conversion): issue an error in formal mode on type
2995 conversion for array types with non-matching static bounds
2996
29972011-08-02 Robert Dewar <dewar@adacore.com>
2998
2999 * par-ch10.adb: Minor code reorganization (use Nkind_In).
3000
30012011-08-02 Ed Schonberg <schonberg@adacore.com>
3002
3003 * par-ch9.adb: save location of entry for proper error message.
3004
30052011-08-02 Javier Miranda <miranda@adacore.com>
3006
3007 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
3008 (Use_Full_View) which permits this routine to climb through the
3009 ancestors using the full-view of private parents.
3010 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
3011 Use_Full_View to true in calls to Is_Ancestor.
3012 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
3013 true in call to Is_Ancestor.
3014 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
3015 Use_Full_View to true in call to Is_Ancestor.
3016 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
3017 call to Is_Ancestor.
3018 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
3019 Use_Full_View to true in calls to Is_Ancestor.
3020 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
3021 Make_Select_Specific_Data_Table, Register_Primitive,
3022 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
3023 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
3024 to true in call to Is_Ancestor.
3025 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
3026 Use_Full_View to true in calls to Is_Ancestor.
3027 * exp_cg.adb
3028 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
3029 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
3030
30312011-08-02 Robert Dewar <dewar@adacore.com>
3032
3033 * gnat_rm.texi: Minor reformatting.
3034 * sem_prag.adb: Minor reformatting.
3035
30362011-08-02 Tristan Gingold <gingold@adacore.com>
3037
3038 * vms_data.ads: Add VMS qualifier for -gnateP.
3039
30402011-08-02 Robert Dewar <dewar@adacore.com>
3041
3042 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
3043 * par-ch7.adb (P_Package): Proper placement of aspects for package
3044 decl/instantiation.
3045 * par-endh.adb (Check_End): Ad Is_Sloc parameter
3046 (End_Statements): Add Is_Sloc parameterr
3047 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
3048 (Check_End): Ad Is_Sloc parameter
3049 (End_Statements): Add Is_Sloc parameterr
3050
30512011-08-02 Vincent Celier <celier@adacore.com>
3052
3053 * ug_words: Add VMS qualifier equivalent to -gnateP:
3054 /SYMBOL_PREPROCESSING.
3055
30562011-08-02 Jose Ruiz <ruiz@adacore.com>
3057
3058 * gnat-style.texi: For hexadecimal numeric literals the typical
3059 grouping of digits is 4 to represent 2 bytes.
3060 A procedure spec which is split into several lines is indented two
3061 characters.
3062
30632011-08-02 Yannick Moy <moy@adacore.com>
3064
3065 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
3066 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
3067 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
3068 properly qualified
3069 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
3070 choice in array aggregate
3071 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
3072 mark as ancestor
3073 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
3074 positional and named aggregate for record, or others in record
3075 aggregate, or multiple choice in record aggregate
3076 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
3077 array operands to logical operations AND, OR and XOR do not have the
3078 same static lower and higher bounds
3079 * sem_ch5.adb, sinfo.ads: Correct typos in comments
3080
30812011-08-01 Robert Dewar <dewar@adacore.com>
3082
3083 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
3084 Replaces Last_Source_Node_In_Sequence.
3085 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
3086 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
3087 parens and blank in string (this was inconsistently implemented).
3088 * errout.ads
3089 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
3090 blank in string (this was inconsistently implemented).
3091 * gnat1drv.adb
3092 (Set_Global_Switches): Set formal mode switches appropriately
3093 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
3094 * par-prag.adb
3095 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
3096 call Set_Error_Msg_Lang to set "spark" as language name.
3097 * par.adb: Remove unnecessary call to set formal language for errout
3098 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
3099 appropriately and call Set_Error_Msg_Lang to set "spark" as language
3100 name.
3101 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
3102 calls to it, moved after resolution so that types are known
3103 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
3104 result of concatenation is not of type String
3105 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
3106 concatenation is not properly restricted
3107 * gnat_rm.texi: Add doc on pragma Spark_95.
3108 * gcc-interface/Makefile.in: Remove obsolete target pairs for
3109 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
3110 * gcc-interface/Make-lang.in: Update dependencies.
3111
31122011-08-01 Javier Miranda <miranda@adacore.com>
3113
3114 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
3115 condition that detects if the overridden operation must replace an
3116 existing entity.
3117
31182011-08-01 Javier Miranda <miranda@adacore.com>
3119
3120 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
3121 code declarations inserted by Insert_Actions in each alternative of the
3122 N_Case_Expression node.
3123
31242011-08-01 Robert Dewar <dewar@adacore.com>
3125
3126 * sem_ch6.adb: Minor code reorganization.
3127 * sem_util.adb: Minor reformatting.
3128
31292011-08-01 Pascal Obry <obry@adacore.com>
3130
3131 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
3132 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
3133
31342011-08-01 Yannick Moy <moy@adacore.com>
3135
3136 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
3137 literal or operator symbol which is prefixed
3138 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
3139 mode on access attributes.
3140 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
3141 that concatenation operands are properly restricted in formal mode
3142 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
3143 Analyze_Concatenation_Operand. Issue an error in formal mode if the
3144 result of the concatenation has a type different from String.
3145 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
3146 Analyze_Quantified_Expression, Analyze_Slice,
3147 Analyze_Null): issue an error in formal mode on unsupported constructs
3148 * sem_ch5.adb
3149 (Analyze_Block_Statement): only issue error on source block statement
3150 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
3151 function which returns the last node in a list of nodes for which
3152 Comes_From_Source returns True, if any
3153 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
3154 Last_Source_Node_In_Sequence
3155 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
3156 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
3157 mode on unsupported constructs
3158 * sem_ch9.adb Do not return after issuing error in formal mode, as the
3159 rest of the actions may be needed later on since the error is marked as
3160 not serious.
3161 * sinfo.ads: Typos in comments.
3162
31632011-08-01 Pascal Obry <obry@adacore.com>
3164
3165 * projects.texi: Minor editing.
3166
31672011-08-01 Yannick Moy <moy@adacore.com>
3168
3169 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
3170 insertion character ~~
3171 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
3172 (Set_Error_Msg_Lang): new procedure which fixes the language for use
3173 with insertion character ~~
3174 (Set_Msg_Text): treat insertion character ~~
3175 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
3176 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
3177 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
3178 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
3179 errors related to the formal language restriction not serious
3180 (insertion character |).
3181 * par.adb (Par): set formal language for error messages if needed
3182 * sem_ch6.adb (Check_Missing_Return): take into account possible
3183 generated statements at the end of the function
3184 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
3185 enumeration value to define a new pragma SPARK_95
3186 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
3187 SPARK_Version): new type and variables to store the SPARK version
3188 (none by default).
3189 (SPARK_Mode): return True when SPARK_Version is set
3190 * par-prag.adb: Correct indentation
3191 (Prag): take Pragma_SPARK_95 into account
3192 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
3193 into account.
3194
31952011-08-01 Robert Dewar <dewar@adacore.com>
3196
3197 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
3198 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
3199 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
3200
32012011-08-01 Pascal Obry <obry@adacore.com>
3202
3203 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
3204 Target_Name to Get_Path call.
3205 (Parse_Single_Project): Likewise.
3206 (Post_Parse_Context_Clause): Likewise.
3207 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
3208 Call Initialise_Project_Path with the proper Target_Name.
3209 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
3210 search path.
3211 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
3212 with the proper Target_Name.
3213 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
3214 Part.Parse routine.
3215 (Parse_Project_And_Apply_Config): Likewise.
3216 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
3217 This is fine as this part of the code is supporting only native
3218 compilation.
3219 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
3220 is fine as this part of the code is supporting only native compilation.
3221
32222011-08-01 Yannick Moy <moy@adacore.com>
3223
3224 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
3225 of homonym, unless the homonym is one of the cases allowed in SPARK
3226 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
3227 package declaration occurring after a body.
3228
32292011-08-01 Robert Dewar <dewar@adacore.com>
3230
3231 * checks.adb, exp_ch4.adb: Minor reformatting.
3232
32332011-08-01 Javier Miranda <miranda@adacore.com>
3234
3235 * einfo.ads (Access_Disp_Table): Fix documentation.
3236 (Dispatch_Table_Wrappers): Fix documentation.
3237
32382011-08-01 Pascal Obry <obry@adacore.com>
3239
3240 * prj-env.adb, prj-env.ads: Minor reformatting.
3241
32422011-08-01 Yannick Moy <moy@adacore.com>
3243
3244 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
3245 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
3246 procedures out of these packages.
3247 * errout.ads, errout.adb
3248 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
3249 procedures in of this package
3250 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
3251 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
3252 on misplaced later vs initial declarations, like in Ada 83
3253 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
3254 formal mode on attribute of private type whose full type declaration
3255 is not visible
3256 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
3257 package declaration inside a package specification
3258 (Analyze_Full_Type_Declaration): issue error in formal mode on
3259 controlled type or discriminant type
3260 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
3261 user-defined operator means that it should come from the source
3262 (New_Overloaded_Entity): issue error in formal mode on overloaded
3263 entity.
3264 * sem_ch6.ads, sem_ch13.ads: typos in comments.
3265
32662011-08-01 Thomas Quinot <quinot@adacore.com>
3267
3268 * atree.adb: Minor reformatting.
3269 * checks.adb: Minor reformatting.
3270
32712011-08-01 Vincent Celier <celier@adacore.com>
3272
3273 * s-parame-vms-ia64.ads: Fix typo in comment
3274 Minor reformatting
3275 * s-parame-vms-restrict.ads: Removed, unused.
3276
32772011-08-01 Javier Miranda <miranda@adacore.com>
3278
3279 * exp_ch3.adb
3280 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
3281 * sem_ch3.adb
3282 (Constrain_Index): Remove side effects in the evaluation of the bounds.
3283 * sem_ch3.ads, sem_ch3.adb
3284 (Is_Constant_Bound): New extended version of the subprogram that was
3285 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
3286 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
3287 * sem_aux.ads (Constant_Value): Fix typo in comment.
3288 * checks.adb (Generate_Index_Checks): New implementation which, for
3289 array objects with constant bounds, generates the runtime check
3290 referencing the bounds of the array type. For other cases this routine
3291 provides its previous behavior obtaining such values from the array
3292 object.
3293 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
3294 parent type.
3295 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
3296 we cannot have semantic interpretations of the new node.
3297
32982011-08-01 Ed Schonberg <schonberg@adacore.com>
3299
3300 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
3301 expressions.
3302
33032011-08-01 Arnaud Charlet <charlet@adacore.com>
3304
3305 * sem_ch8.adb: Minor code editing.
3306 * s-vxwext.adb: Remove trailing space.
3307 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
3308 consistency with other files.
3309
33102011-08-01 Thomas Quinot <quinot@adacore.com>
3311
3312 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
3313
33142011-08-01 Ed Schonberg <schonberg@adacore.com>
3315
3316 * par-ch10.adb: reject parameterized expressions as compilation unit.
3317 * sem_ch4.adb: handle properly conditional expression with overloaded
3318 then_clause and no else_clause.
3319
33202011-08-01 Tristan Gingold <gingold@adacore.com>
3321
3322 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
3323 like done by System.Aux_DEC.
3324 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
3325
33262011-08-01 Yannick Moy <moy@adacore.com>
3327
3328 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
3329 missing label at end of declaration (subprogram or package)
3330 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
3331 of positional and named parameter association
3332 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
3333 Error_Msg_SP which adds a prefix to the error message giving the name
3334 of the formal language analyzed
3335 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
3336 access result type in subprogram, unconstrained array as result type,.
3337 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
3338 procedure
3339 * sem_ch8.adb: Code clean up.
3340
33412011-08-01 Javier Miranda <miranda@adacore.com>
3342
3343 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
3344 * einfo.ads (Access_Disp_Table): Fix documentation.
3345 (Dispatch_Table_Wrappers): Fix documentation.
3346 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
3347 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
3348 to enforce the documentation of this attribute.
3349 (Set_Is_Interface): Cleanup the assertion.
3350 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
3351 the Underlying_Type entity before reading attribute Access_Disp_Table.
3352 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
3353 Locate the Underlying_Type before reading attribute Access_Disp_Table.
3354 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
3355 the Underlying_Type entity before reading attribute Access_Disp_Table.
3356 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
3357 Locate the Underlying_Type entity before reading attribute
3358 Access_Disp_Table.
3359
33602011-08-01 Ed Schonberg <schonberg@adacore.com>
3361
3362 * s-poosiz.ads: Additional overriding indicators.
3363
33642011-08-01 Yannick Moy <moy@adacore.com>
3365
3366 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
3367 formal mode.
3368 (Analyze_Iteration_Scheme): issue error in formal mode when loop
3369 parameter specification does not include a subtype mark.
3370 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
3371 formal mode on abstract subprogram.
3372 (Analyze_Subprogram_Specification): issue error in formal mode on
3373 user-defined operator.
3374 (Process_Formals): issue error in formal mode on access parameter and
3375 default expression.
3376 * sem_ch9.adb (Analyze_Abort_Statement,
3377 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
3378 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
3379 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
3380 Analyze_Requeue, Analyze_Selective_Accept,
3381 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
3382 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
3383 issue error in formal mode on user-defined raise statement.
3384
33852011-08-01 Thomas Quinot <quinot@adacore.com>
3386
3387 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
3388 declaration being hidden when overriding an implicit inherited
3389 subprogram.
3390 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
3391 (-gnats), do not complain about a source file that contains only a
3392 pragma No_Body.
3393
33942011-08-01 Ed Schonberg <schonberg@adacore.com>
3395
3396 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
3397 variable if already set.
3398
33992011-08-01 Arnaud Charlet <charlet@adacore.com>
3400
3401 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
3402 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
3403 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
3404 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
3405 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
3406 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
3407 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
3408 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
3409 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
3410 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
3411 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
3412 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
3413 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
3414 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
3415 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
3416 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
3417 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
3418 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
3419 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
3420 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
3421 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
3422 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
3423 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
3424 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
3425 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
3426 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
3427 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
3428 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
3429 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
3430 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
3431 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
3432 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
3433 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
3434 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
3435 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
3436 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
3437 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
3438 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
3439 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
3440 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
3441 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
3442 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
3443 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
3444 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
3445 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
3446 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
3447 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
3448 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
3449 s-osinte-mingw.ads: Update to GPLv3 run-time license.
3450 Use GNAT instead of GNARL.
3451
34522011-08-01 Bob Duff <duff@adacore.com>
3453
3454 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
3455 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
3456 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
3457 reformatting.
3458
34592011-08-01 Yannick Moy <moy@adacore.com>
3460
3461 * debug.adb (d.D) reverve flag for the SPARK mode
3462 (d.E) reverve flag for SPARK generation mode
3463 (d.F) reverve flag for Why generation mode
3464 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
3465 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
3466 functions which return True when the corresponding modes are set
3467 (Formal_Language): return "spark" or "alfa" when in formal verification
3468 mode.
3469 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
3470 Error_Msg to prefix the error message with a tag giving the formal
3471 language
3472 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
3473 message with a tag giving the formal language
3474 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
3475 block statement
3476 (Analyze_Case_Statement): issue error in formal mode on case statement
3477 with a single "others" case alternative
3478 (Analyze_Exit_Statement): issue errors in formal mode on exit
3479 statements which do not respect SPARK restrictions
3480 (Analyze_Goto_Statement): issue error in formal mode on goto statement
3481 (Check_Unreachable_Code): always issue an error (not a warning) in
3482 formal mode on unreachable code (concerns both code after an infinite
3483 loop and after an unconditional jump, both not allowed in SPARK)
3484 * sem_ch6.adb (Analyze_Return_Statement): add call to
3485 Set_Return_Present for a procedure containing a return statement
3486 (already done for functions in Analyze_Function_Return)
3487 (Analyze_Function_Return): issue error in formal mode on extended
3488 return or if return is not last statement in function
3489 (Check_Missing_Return): issue error in formal mode if function does
3490 not end with return or if procedure contains a return
3491 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
3492 function to detect if there is an inner scope of its parameter S which
3493 is a loop.
3494
34952011-08-01 Thomas Quinot <quinot@adacore.com>
3496
3497 * sem_ch6.ads: Minor reformatting.
3498
34992011-08-01 Javier Miranda <miranda@adacore.com>
3500
3501 * sem_util.adb (Abstract_Interface_List): Complete condition when
3502 processing private type declarations to avoid reading unavailable
3503 attribute.
3504 (Is_Synchronized_Tagged_Type): Complete condition when processing
3505 private extension declaration nodes to avoid reading unavailable
3506 attribute.
3507
35082011-08-01 Thomas Quinot <quinot@adacore.com>
3509
3510 * sem_ch3.adb: Minor reformatting.
3511
35122011-08-01 Thomas Quinot <quinot@adacore.com>
3513
3514 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
3515 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
3516 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
3517 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
3518 for VMS, instead parametrize the common implementation with
3519 System.Parameters declarations.
3520
35212011-08-01 Eric Botcazou <ebotcazou@adacore.com>
3522
3523 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
3524
35252011-08-01 Tristan Gingold <gingold@adacore.com>
3526
3527 * seh_init.c: Fix SEH handler installation on win64.
3528
35292011-08-01 Ed Schonberg <schonberg@adacore.com>
3530
3531 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
3532 double analysis of an anonymous access to subprogram, because it can
3533 lead to improper sharing of profiles and a back-end crash.
3534
35352011-08-01 Robert Dewar <dewar@adacore.com>
3536
3537 * make.adb, sem_ch4.adb: Minor reformatting.
3538 * gcc-interface/Make-lang.in: Update dependencies.
3539 * sem_util.adb, exp_ch5.adb: Minor reformatting.
3540
35412011-08-01 Arnaud Charlet <charlet@adacore.com>
3542
3543 * gnat_rm.texi: Fix definition of Long_Integer.
3544
35452011-08-01 Ed Schonberg <schonberg@adacore.com>
3546
3547 * exp_aggr.adb: check limit size of static aggregate unconditionally,
3548 to prevent storage exhaustion.
3549 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
3550 finalized is a function body, insert the cleanup code before the final
3551 return statement, to prevent spurious warnings.
3552 * s-pooglo.ads: add overriding indicator.
3553
35542011-08-01 Ed Schonberg <schonberg@adacore.com>
3555
3556 * sem_ch4.adb (Operator_Check): improve error message when both a
3557 with_clause and a use_clause are needed to make operator usage legal.
3558 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
3559 determine whether a compilation unit is visible within an other,
3560 either through a with_clause in the current unit, or a with_clause in
3561 its library unit or one one of its parents.
3562
35632011-08-01 Ed Schonberg <schonberg@adacore.com>
3564
3565 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
3566 over an arbitrary expression of an array or container type.
3567 * lib-xref.adb: clarify comment.
3568
35692011-08-01 Bob Duff <duff@adacore.com>
3570
3571 * einfo.ads: Minor reformatting.
3572 * debug.adb: Minor comment improvement.
3573
35742011-08-01 Javier Miranda <miranda@adacore.com>
3575
3576 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
3577 consider hidden subprograms as valid candidates.
3578
35792011-08-01 Arnaud Charlet <charlet@adacore.com>
3580
3581 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
3582
35832011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
3584
3585 * gnat_ugn.texi: Fix typo.
3586
35872011-08-01 Robert Dewar <dewar@adacore.com>
3588
3589 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
3590 lib-xref.adb: Minor reformatting
3591
35922011-08-01 Gary Dismukes <dismukes@adacore.com>
3593
3594 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
3595 when to generate a call to Move_Final_List.
3596 (Has_Controlled_Parts): Remove this function.
3597
35982011-08-01 Geert Bosch <bosch@adacore.com>
3599
3600 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
3601 "," in choice list.
3602
36032011-08-01 Thomas Quinot <quinot@adacore.com>
3604
3605 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
3606 explicit raise of a predefined exception as Comes_From_Source if the
3607 original N_Raise_Statement comes from source.
3608
36092011-08-01 Robert Dewar <dewar@adacore.com>
3610
3611 * sinfo.ads: Add comment.
3612 * sem_ch6.adb: Minor reformatting.
3613
36142011-08-01 Robert Dewar <dewar@adacore.com>
3615
3616 * freeze.adb (Freeze_Entity): Refine check for bad component size
3617 clause to avoid rejecting confirming clause when atomic/aliased present.
3618
36192011-08-01 Ed Schonberg <schonberg@adacore.com>
3620
3621 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
3622 better determine whether an entity reference is a write.
3623 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
3624 subcomponent.
3625 * lib-xref.adb (Output_References): Do no suppress a read reference at
3626 the same location as an immediately preceeding modify-reference, to
3627 handle properly in-out actuals.
3628
36292011-08-01 Tristan Gingold <gingold@adacore.com>
3630
3631 * env.c (__gnat_setenv) [VMS]: Refine previous change.
3632
36332011-08-01 Quentin Ochem <ochem@adacore.com>
3634
3635 * i-cstrin.adb (New_String): Changed implementation, now uses only the
3636 heap to compute the result.
3637
36382011-08-01 Robert Dewar <dewar@adacore.com>
3639
3640 * atree.ads: Minor reformatting.
3641
36422011-08-01 Emmanuel Briot <briot@adacore.com>
3643
3644 * g-expect.adb (Get_Command_Output): Fix memory leak.
3645
36462011-08-01 Geert Bosch <bosch@adacore.com>
3647
3648 * cstand.adb (P_Float_Type): New procedure to print the definition of
3649 predefined fpt types.
3650 (P_Mixed_Name): New procedure to print a name using mixed case
3651 (Print_Standard): Use P_Float_Type for printing floating point types
3652 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
3653 precision IEEE float.
3654
36552011-08-01 Thomas Quinot <quinot@adacore.com>
3656
3657 * sem_ch3.adb: Minor reformatting.
3658
36592011-08-01 Ed Schonberg <schonberg@adacore.com>
3660
3661 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
3662 the completion of a generic function, insert the new body rather than
3663 rewriting the original.
3664
36652011-08-01 Yannick Moy <moy@adacore.com>
3666
3667 * sinfo.ads, errout.ads: Typos in comments.
3668
36692011-08-01 Robert Dewar <dewar@adacore.com>
3670
3671 * par-endh.adb: Minor reformatting.
3672
36732011-08-01 Robert Dewar <dewar@adacore.com>
3674
3675 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
3676 (Pre_Post_Aspects): New subtype.
3677 * par-ch12.adb (P_Generic): New syntax for aspects in packages
3678 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
3679 * par-ch7.adb (P_Package): Remove Decl parameter
3680 (P_Package): Handle new syntax for aspects (before IS)
3681 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
3682 new aspect syntax
3683 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
3684 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
3685 (P_Package): Remove Decl parameter
3686 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
3687 aspects
3688 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
3689 specs
3690 * sem_util.ads, sem_util.adb (Static_Boolean): New function
3691 * sinfo.ads: Document new syntax for aspects in packages etc.
3692 * sprint.adb: Handle new syntax of aspects before IS in package
3693
36942011-08-01 Thomas Quinot <quinot@adacore.com>
3695
3696 * atree.ads: Minor reformatting.
3697 * sem_prag.adb: Minor reformatting.
3698
36992011-08-01 Robert Dewar <dewar@adacore.com>
3700
3701 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
3702 case expr alternative.
3703
37042011-08-01 Ed Schonberg <schonberg@adacore.com>
3705
3706 * sem_ch12.adb: Fix typo.
3707
37082011-08-01 Geert Bosch <bosch@adacore.com>
3709
3710 * sem_prag.adb (Check_No_Link_Name): New procedure.
3711 (Process_Import_Or_Interface): Use Check_No_Link_Name.
3712 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
3713 instead of Standard_Long_Long_Float_Size global. Preparation for
3714 eventual removal of per type constants.
3715 * exp_util.ads (Get_Stream_Size): New function returning the stream
3716 size value of subtype E.
3717 * exp_util.adb (Get_Stream_Size): Implement new function.
3718 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
3719 function.
3720 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
3721 * einfo.adb:
3722 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
3723
37242011-08-01 Geert Bosch <bosch@adacore.com>
3725
3726 * cstand.adb: Fix comments.
3727 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
3728 count of arguments.
3729
37302011-08-01 Robert Dewar <dewar@adacore.com>
3731
3732 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
3733
37342011-08-01 Geert Bosch <bosch@adacore.com>
3735
3736 * atree.ads: Fix comment.
3737
37382011-08-01 Robert Dewar <dewar@adacore.com>
3739
3740 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
3741 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
3742 * par.adb: Add with for Namet.Sp.
3743 * par-tchk.adb: Minor reformatting.
3744
37452011-08-01 Vincent Celier <celier@adacore.com>
3746
3747 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
3748 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
3749 of the init procedure of a SAL.
3750 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
3751 New procedure.
3752
37532011-08-01 Thomas Quinot <quinot@adacore.com>
3754
3755 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
3756 reformatting.
3757
37582011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
3759
3760 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
3761
37622011-08-01 Thomas Quinot <quinot@adacore.com>
3763
3764 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
3765 conformant with its spec (return True only for types that have
3766 an overriding Initialize primitive operation that prevents them from
3767 having preelaborable initialization).
3768 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
3769 initialization for controlled types in Ada 2005 or later mode.
3770
37712011-08-01 Robert Dewar <dewar@adacore.com>
3772
3773 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
3774 Postcondition.
3775 (Same_Aspect): New function.
3776 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
3777 Type_Invariant, Precondition, Postcondition.
3778 * snames.ads-tmpl: Add Name_Type_Invariant.
3779
37802011-08-01 Robert Dewar <dewar@adacore.com>
3781
3782 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
3783 here.
3784 (Freeze_All_Ent): Fix error in handling inherited aspects.
3785 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
3786 already analyzed, but don't skip entire processing of a declaration,
3787 that's wrong in some cases of declarations being rewritten.
3788 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
3789 Don't delay for integer, string literals
3790 Treat predicates in usual manner for delay, remove special case code,
3791 not needed.
3792 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
3793 (Build_Predicate_Function): Update saved expression in aspect
3794 (Build_Invariant_Procedure): Update saved expression in aspect
3795 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
3796 of replacement of discriminant references if the reference is simple.
3797
37982011-08-01 Robert Dewar <dewar@adacore.com>
3799
3800 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
3801 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
3802 Static_Predicate and Dynamic_Predicate.
3803 (Build_Predicate_Function): Add processing for Static_Predicate
3804 and Dynamic_Predicate.
3805 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
3806 (From_Static_Predicate): New flag
3807 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
3808
38092011-08-01 Robert Dewar <dewar@adacore.com>
3810
3811 * usage.adb: Documentation cleanup for Ada version modes in usage.
3812 * expander.adb: Minor reformatting.
3813
38142011-08-01 Robert Dewar <dewar@adacore.com>
3815
3816 * atree.ads: Minor comment fix.
3817 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
3818 a-witeio.ads, sem_prag.adb: Minor reformatting.
3819
38202011-08-01 Doug Rupp <rupp@adacore.com>
3821
3822 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
3823 pointers. Use descrip.h header file for convenience. Add some
3824 comments.
3825
38262011-08-01 Robert Dewar <dewar@adacore.com>
3827
3828 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
3829 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
3830 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
3831 New procedure.
3832 (Check_Aspect_At_End_Of_Declarations): New procedure
3833 (Analye_Aspect_Specification): Minor changes for above procedures
3834 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
3835 specification node as well.
3836
38372011-08-01 Pascal Obry <obry@adacore.com>
3838
3839 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
3840 Windows files. Use GetFilesAttributes() in this case to check for file
3841 existence instead of returning with an error code.
3842
38432011-08-01 Vincent Celier <celier@adacore.com>
3844
3845 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
3846 High is above Source length.
3847
38482011-08-01 Robert Dewar <dewar@adacore.com>
3849
3850 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
3851
38522011-08-01 Robert Dewar <dewar@adacore.com>
3853
3854 * aspects.ads (Boolean_Aspects): New subtype.
3855 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
3856 for derived types in cases where the parent type and derived type have
3857 aspects.
3858 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
3859 with aspects when parent type also has aspects.
3860 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
3861 boolean expression at this point).
3862 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
3863 accordance with final decision on the Ada 2012 feature.
3864 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
3865
38662011-08-01 Matthew Heaney <heaney@adacore.com>
3867
3868 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
3869
38702011-08-01 Pascal Obry <obry@adacore.com>
3871
3872 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
3873 Fix Replace_Slice when High is above current string size.
3874 (Replace_Slice): Fix DL computation when High is above current
3875 string length.
3876
38772011-08-01 Gary Dismukes <dismukes@adacore.com>
3878
3879 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
3880
38812011-08-01 Matthew Heaney <heaney@adacore.com>
3882
3883 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
3884 of node.
3885
38862011-08-01 Pascal Obry <obry@adacore.com>
3887
3888 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
3889 reformatting.
3890
38912011-08-01 Ed Schonberg <schonberg@adacore.com>
3892
3893 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
3894 access to protected subprograms in generic bodies.
3895 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
3896 protected type, indicate that the convention of the subprogram is
3897 Convention_Protected, because it may be used in subsequent declarations
3898 within the protected declaration.
3899
39002011-08-01 Vincent Celier <celier@adacore.com>
3901
3902 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
3903 and "final" procedures when the name of the library is "ada", to avoid
3904 duplicate symbols "adainit" and "adafinal" in executables.
3905
39062011-08-01 Ed Schonberg <schonberg@adacore.com>
3907
3908 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
3909 quantified expression that appears within a postcondition and uses the
3910 Ada2012 'Result attribute.
3911
39122011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3913
3914 * init.c (__gnat_error_handler): Cast reason to int.
3915 (__gnat_install_handler): Explain sa_sigaction use.
3916
39172011-07-24 Eric Botcazou <ebotcazou@adacore.com>
3918
3919 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
3920 subprogram has copy-in copy-out parameters, try to promote the mode of
3921 the return type if it is passed in registers.
3922
39232011-07-24 Eric Botcazou <ebotcazou@adacore.com>
3924
3925 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
3926 left operand as addressable.
3927
39282011-07-24 Eric Botcazou <ebotcazou@adacore.com>
3929
3930 * gcc-interface/gigi.h (build_function_stub): Remove.
3931 (build_return_expr): Likewise.
3932 (convert_vms_descriptor): Declare.
3933 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
3934 (build_function_stub): Move to...
3935 * gcc-interface/utils2.c (build_return_expr): Move to...
3936 * gcc-interface/trans.c (build_function_stub): ...here.
3937 (build_return_expr): ...here.
3938 (Subprogram_Body_to_gnu): Add local variable for language_function.
3939 Disconnect the parameter attributes cache, if any, once done with it.
3940 Call end_subprog_body only after setting the end_locus.
3941 Build the stub associated with the function, if any, at the very end.
3942 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
3943 variables and streamline control flow.
3944
39452011-07-23 Arnaud Charlet <charlet@adacore.com>
3946
3947 PR ada/49819
3948 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
3949 g-trasym-dwarf.adb.
3950
39512011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3952
3953 PR bootstrap/49794
3954 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
3955 Assign to act.sa_sigaction.
3956 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
3957 current->return_address to char * before arithmetic.
3958
39592011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3960
3961 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
3962 Correct argument types.
3963 Extract code from reason.
3964 (__gnat_install_handler): Assign to act.sa_sigaction.
3965
39662011-07-21 Eric Botcazou <ebotcazou@adacore.com>
3967
3968 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
3969 (GNAT1_OBJS): ...here.
3970
39712011-07-15 Eric Botcazou <ebotcazou@adacore.com>
3972
3973 PR ada/48711
3974 * g-socthi-mingw.adb (Fill): Fix formatting.
3975
3976 * gcc-interface/gigi.h: Move around comment.
3977
39782011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
3979
3980 PR ada/46350
3981 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
3982
39832011-07-14 Florian Weimer <fw@deneb.enyo.de>
3984
3985 PR ada/48711
3986 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
3987
39882011-07-13 Eric Botcazou <ebotcazou@adacore.com>
3989
3990 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
3991 range comparison if Pmode is SImode.
3992
39932011-07-12 Laurent GUERBY <laurent@guerby.net>
3994 Eric Botcazou <ebotcazou@adacore.com>
3995
3996 * adadecode.c: Wrap up in extern "C" block.
3997 * adadecode.h: Likewise.
3998 * adaint.c: Likewise. Remove 'const' keyword.
3999 * adaint.h: Likewise.
4000 * argv.c: Likewise.
4001 * atree.h: Likewise.
4002 * cio.c: Likewise.
4003 * cstreams.c: Likewise.
4004 * env.c: Likewise.
4005 * exit.c: Likewise.
4006 * fe.h: Likewise.
4007 * final.c: Likewise.
4008 * init.c: Likewise.
4009 * initialize.c: Likewise.
4010 * link.c: Likewise.
4011 * namet.h: Likewise.
4012 * nlists.h: Likewise.
4013 * raise.c: Likewise.
4014 * raise.h: Likewise.
4015 * repinfo.h: Likewise.
4016 * seh_init.c: Likewise.
4017 * targext.c: Likewise.
4018 * tracebak.c: Likewise.
4019 * uintp.h: Likewise.
4020 * urealp.h: Likewise.
4021 * xeinfo.adb: Wrap up generated C code in extern "C" block.
4022 * xsinfo.adb: Likewise.
4023 * xsnamest.adb: Likewise.
4024 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
4025 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
4026 * gcc-interface/misc.c: Likewise.
4027 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
4028 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
4029 ada/targext.o here...
4030 (GNAT_ADA_OBJS): ...and not here.
4031 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
4032 (GNATBIND_OBJS): Reorder.
4033
40342011-07-07 Richard Henderson <rth@redhat.com>
4035
4036 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
4037 dwarf2out_frame_init.
4038
40392011-07-07 Eric Botcazou <ebotcazou@adacore.com>
4040
4041 * gcc-interface/misc.c (gnat_init): Tweak previous change.
4042
40432011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4044
4045 PR target/39150
4046 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
4047
40482011-07-06 Richard Guenther <rguenther@suse.de>
4049
4050 * gcc-interface/misc.c (gnat_init): Merge calls to
4051 build_common_tree_nodes and build_common_tree_nodes_2.
4052 Re-initialize boolean_false_node.
4053
40542011-07-02 Eric Botcazou <ebotcazou@adacore.com>
4055 Olivier Hainque <hainque@adacore.com>
4056 Nicolas Setton <setton@adacore.com>
4057
4058 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
4059 the type according to the ARTIFICIAL_P parameter.
4060 (create_type_decl): Likewise.
4061 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
4062
40632011-07-01 Eric Botcazou <ebotcazou@adacore.com>
4064
4065 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
4066 (gnatbind): Likewise.
4067
40682011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4069
4070 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
4071
40722011-06-18 Eric Botcazou <ebotcazou@adacore.com>
4073
4074 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
4075 local variable throughout. Remove useless call to Base_Type.
4076 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
4077 Take it also into account for the volatileness of the field. Set the
4078 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
4079
40802011-06-18 Eric Botcazou <ebotcazou@adacore.com>
4081
4082 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
4083 on a dereference built for a by-ref object if it has an address clause.
4084
40852011-06-18 Eric Botcazou <ebotcazou@adacore.com>
4086
4087 * einfo.ads (Address_Taken): Document use for the second argument of
4088 Asm_Input and Asm_Output attributes.
4089 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
4090 argument is an entity name, then set Address_Taken on it.
4091 <Attribute_Asm_Output>: Likewise.
4092 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
4093 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
4094 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
4095 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
4096
40972011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
4098
4099 PR middle-end/46500
4100 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
4101
41022011-06-14 Joseph Myers <joseph@codesourcery.com>
4103
4104 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
4105 (ada/utils.o): Update dependencies.
4106 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
4107 ../../../libcpp/libcpp.a.
4108 * gcc-interface/utils.c: Include common/common-target.h.
4109 (process_attributes): Use targetm_common.have_named_sections.
4110
41112011-06-07 Richard Guenther <rguenther@suse.de>
4112
4113 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
4114 set_sizetype.
4115
41162011-06-06 Eric Botcazou <ebotcazou@adacore.com>
4117
4118 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
4119 TREE_THIS_NOTRAP flag.
4120
41212011-06-06 Eric Botcazou <ebotcazou@adacore.com>
4122
4123 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
4124 Fix thinko.
4125
41262011-06-06 Eric Botcazou <ebotcazou@adacore.com>
4127
4128 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
4129 constants whose full view has discriminants specially.
4130
41312011-06-06 Eric Botcazou <ebotcazou@adacore.com>
4132
4133 * gcc-interface/utils.c: Include diagnostic.h.
4134 (gnat_write_global_declarations): Output debug information for all
4135 global type declarations before finalizing the compilation unit.
4136 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
4137
41382011-05-25 Jakub Jelinek <jakub@redhat.com>
4139
4140 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
4141
41422011-05-25 Kai Tietz <ktietz@redhat.com>
4143
4144 * adaint.c (__gnat_to_canonical_file_list_next): Use array
4145 initialization instead of const/none-const pointer assignment.
4146
41472011-05-24 Joseph Myers <joseph@codesourcery.com>
4148
4149 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
4150 $(EXTRA_GNAT1_OBJS).
4151 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
4152 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
4153 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
4154 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
4155 libcommon-target.a instead of prefix.o.
4156
41572011-05-21 Joseph Myers <joseph@codesourcery.com>
4158
4159 PR ada/49097
4160 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
4161
41622011-05-20 Joseph Myers <joseph@codesourcery.com>
4163
4164 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
4165 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
4166 instead of version.o.
4167
41682011-05-18 Kai Tietz <ktietz@redhat.com>
4169
4170 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
4171 boolean_false_node instead of integer_zero_node.
4172 (convert_with_check): Likewise.
4173 * gcc-interface/decl.c (choices_to_gnu): Likewise.
4174
41752011-05-12 Eric Botcazou <ebotcazou@adacore.com>
4176
4177 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
4178 type of the parameter is an unconstrained array, convert the actual to
4179 the type of the formal in the In Out and Out cases as well.
4180
41812011-05-11 Nathan Froyd <froydnj@codesourcery.com>
4182
4183 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
4184 call build_function_type_array or build_varargs_function_type_array
4185 instead.
4186 (create_subprog_type): Don't call build_function_type; call
4187 build_function_type_vec instead.
4188
41892011-05-11 Nathan Froyd <froydnj@codesourcery.com>
4190
4191 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
4192 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
4193 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
4194
41952011-05-07 Eric Botcazou <ebotcazou@adacore.com>
4196
4197 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
4198
4199 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
4200 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
4201
42022011-05-05 Nathan Froyd <froydnj@codesourcery.com>
4203
4204 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
4205
42062011-05-05 Nathan Froyd <froydnj@codesourcery.com>
4207
4208 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
4209 instead of accessing TYPE_ARG_TYPES directly.
4210 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
4211
42122011-05-05 Eric Botcazou <ebotcazou@adacore.com>
4213
4214 PR ada/48844
4215 * gcc-interface/gigi.h (get_variant_part): Declare.
4216 * gcc-interface/decl.c (get_variant_part): Make global.
4217 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
4218 types have the same constant size, are record types and T1 has a
4219 variant part while T2 doesn't.
4220
42212011-05-05 Eric Botcazou <ebotcazou@adacore.com>
4222
4223 * gcc-interface/utils.c (begin_subprog_body): Do not call
4224 get_pending_sizes.
4225 (end_subprog_body): Likewise.
4226
42272011-05-04 Richard Guenther <rguenther@suse.de>
4228
4229 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
4230 int_const_binop.
4231 (pos_to_constructor): Likewise.
4232
42332011-05-03 Nathan Froyd <froydnj@codesourcery.com>
4234 Eric Botcazou <ebotcazou@adacore.com>
4235
4236 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
4237 of build_function_type. Adjust calls to...
4238 (build_raise_check): ...this. Do not take a void_tree parameter.
4239 Call build_function_type_list instead of build_function_type.
4240 Fix head comment and swap couple of conditional blocks.
4241
42422011-04-30 Eric Botcazou <ebotcazou@adacore.com>
4243
4244 * gnatvsn.ads (Library_Version): Bump to 4.7.
4245 (Current_Year): Bump to 2011.
4246
42472011-04-29 Michael Matz <matz@suse.de>
4248
4249 * gcc-interface/misc.c (gnat_handle_option): Set
4250 warn_maybe_uninitialized.
4251
42522011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
4253
4254 * gnat_ugn.texi (Complexity Metrics Control): Update link to
4255 the Watson/McCabe paper.
4256
42572011-04-23 Jim Meyering <meyering@redhat.com>
4258
4259 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
4260
42612011-04-22 Eric Botcazou <ebotcazou@adacore.com>
4262
4263 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
4264 onto the new type.
4265
42662011-04-22 Eric Botcazou <ebotcazou@adacore.com>
4267
4268 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
4269 parameter.
4270 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
4271 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
4272 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
4273 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
4274 <all>: Do not set flags on the reused DECL node coming from an alias.
4275 Set DECL_IGNORED_P on the DECL node built for subprograms if they
4276 don't need debug info here...
4277 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
4278 (gigi): Adjust calls to create_subprog_decl.
4279 (build_raise_check): Likewise.
4280 (establish_gnat_vms_condition_handler): Likewise.
4281 (Compilation_Unit_to_gnu): Likewise.
4282 (gnat_to_gnu): Likewise.
4283
42842011-04-21 Eric Botcazou <ebotcazou@adacore.com>
4285
4286 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
4287 (NO_REORDER_ADAFLAGS): New variable.
4288 (EXTRA_GNATTOOLS): Always define.
4289 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
4290 Clean up and adjust list of files compiled with special options.
4291 * gcc-interface/Make-lang.in: Likewise.
4292 (ada/decl.o): Cosmetical change.
4293 (ada/misc.o): Remove dependency on $(PLUGIN_H).
4294
42952011-04-20 Jim Meyering <meyering@redhat.com>
4296
4297 * initialize.c (__gnat_initialize): Remove useless if-before-free.
4298
42992011-04-17 Eric Botcazou <ebotcazou@adacore.com>
4300
4301 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
4302 $(CFLAGS) on the link line.
4303
43042011-04-17 Eric Botcazou <ebotcazou@adacore.com>
4305
4306 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
4307 padded type built for the return type if it is unconstrained.
4308
43092011-04-14 Nathan Froyd <froydnj@codesourcery.com>
4310
4311 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
4312
43132011-04-12 Nathan Froyd <froydnj@codesourcery.com>
4314
4315 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
4316 before calling TREE_CHAIN.
4317 * gcc-interface/misc.c (gnat_init_ts): New function.
4318 (LANG_HOOKS_INIT_TS): Define.
4319
43202011-04-12 Martin Jambor <mjambor@suse.cz>
4321
4322 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
4323 instead of cgraph_node.
4324
43252011-04-08 Eric Botcazou <ebotcazou@adacore.com>
4326
4327 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
4328 alignment on fields of the RETURN type built for the Copy-In Copy-Out
4329 mechanism.
4330
43312011-04-08 Eric Botcazou <ebotcazou@adacore.com>
4332
4333 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
4334 of aggregate types that contain a placeholder.
4335
43362011-04-08 Nathan Froyd <froydnj@codesourcery.com>
4337
4338 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
4339 TYPE_ARG_TYPES.
4340 (handle_type_generic_attribute): Likewise.
4341
43422011-04-04 Eric Botcazou <ebotcazou@adacore.com>
4343
4344 PR ada/47163
4345 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
4346
43472011-04-04 Kai Tietz <ktietz@redhat.com>
4348
4349 PR ada/47163
4350 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
4351 to flag value.
4352
43532011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4354
4355 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
4356 type case, do not strip a padding type around the array type.
4357
43582011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4359
4360 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
4361 types.
4362
43632011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4364
4365 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
4366 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
4367 code for -feliminate-unused-debug-types.
4368 (gnat_post_options): Likewise.
4369
43702011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4371
4372 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
4373 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
4374 distinct copy.
4375
43762011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4377
4378 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
4379 DECL_ARTIFICIAL flag on enumeration types.
4380
43812011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4382
4383 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
4384 fat pointer types artificial unconditionally.
4385 <E_Array_Subtype>: Attach the base array type as a parallel type if it
4386 isn't artificial.
4387
43882011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4389
4390 * gcc-interface/gigi.h (get_dummy_type): Declare.
4391 (build_dummy_unc_pointer_types): Likewise.
4392 (finish_fat_pointer_type): Likewise.
4393 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
4394 fat pointer type has been built, complete it in place.
4395 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
4396 and thin pointers. Remove useless variable.
4397 (finish_fat_pointer_type): Make global and move to...
4398 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
4399 (get_dummy_type): New function.
4400 (build_dummy_unc_pointer_types): Likewise.
4401 (gnat_pushdecl): Propage the name to the anonymous variants only.
4402 (update_pointer_to): Only adjust the pointer types in the unconstrained
4403 array case.
4404
44052011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4406
4407 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
4408 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
4409 if this is a Taft amendment type and the full declaration is available.
4410 * gcc-interface/trans.c (process_type): Likewise.
4411 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
4412 (process_freeze_entity): Likewise.
4413 * gcc-interface/utils.c (dummy_global): New static variable.
4414 (gnat_write_global_declarations): If there are types declared as used
4415 at the global level, insert them in the global hash table.
4416
44172011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4418
4419 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
4420 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
4421 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
4422 copy.
4423 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
4424 flag of the type accordingly.
4425 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
4426
44272011-04-02 Eric Botcazou <ebotcazou@adacore.com>
4428
4429 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
4430 finalizing types when updating the pointers to the designated type.
4431 <all>: Finalize the deferred types even if we didn't defer processing
4432 of incomplete types in this invocation.
4433
44342011-04-01 Olivier Hainque <hainque@adacore.com>
4435 Nicolas Setton <setton@adacore.com>
4436 Eric Botcazou <ebotcazou@adacore.com>
4437
4438 * gcc-interface/misc.c (gnat_descriptive_type): New function.
4439 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
4440
44412011-03-28 Kai Tietz <ktietz@redhat.com>
4442
4443 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
4444 Windows targets.
4445 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
4446 * system-mingw.ads (System): Change ZCX_By_Default default to True.
4447
4448 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
4449
44502011-03-28 Tristan Gingold <gingold@adacore.com>
4451
4452 PR ada/44431
4453 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
4454 Use ada output of gnatbind.
4455 (ada/b_gnatb.adb): Ditto.
4456 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
4457 (ada.mostlyclean, ada.stage1)
4458 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
4459 (ada.stagefeedback): Adjust.
4460 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
4461 Use ada output of gnatbind.
4462 (b_gnatm.adb): Ditto.
4463 (b_gnatl.o, b_gnatm.o): New rules.
4464
44652011-03-26 Eric Botcazou <ebotcazou@adacore.com>
4466
4467 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
4468 for the padded type built to support a specified size or alignment.
4469
44702011-03-26 Eric Botcazou <ebotcazou@adacore.com>
4471
4472 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
4473 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
4474 unconditionally to the end of the unit when the designated type is
4475 limited_with'ed.
4476 <all>: Rename local variable. Attempt to un-defer types only and do it
4477 for limited_with'ed types as well.
4478 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
4479 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
4480 consistently and remove redundant call to finalize_from_with_types.
4481
44822011-03-26 Eric Botcazou <ebotcazou@adacore.com>
4483
4484 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
4485 subprograms without a previous spec declared in the same unit.
4486 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
4487 subprograms at the end of the unit instead of at the beginning.
4488 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
4489 isn't public for the special handling of non-inline functions nested
4490 inside inline external functions.
4491
44922011-03-25 Jeff Law <law@redhat.com>
4493
4494 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
4495
44962011-03-24 Eric Botcazou <ebotcazou@adacore.com>
4497
4498 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
4499 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
4500 to compute Set_Size_Depends_On_Discriminant.
4501 (Layout_Type): Call it on array types in back-end layout mode.
4502 * sem_util.adb (Requires_Transient_Scope): Return true for array
4503 types only if the size depends on the value of discriminants.
4504 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
4505 type if the RHS is a call to a function that returns an unconstrained
4506 type with default discriminant.
4507
45082011-03-24 Eric Botcazou <ebotcazou@adacore.com>
4509
4510 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
4511 non-conversion to the nominal result type at the end.
4512
45132011-03-23 Eric Botcazou <ebotcazou@adacore.com>
4514
4515 * gcc-interface/trans.c (create_temporary): New function taken from...
4516 (create_init_temporary): ...here. Call it.
4517 (call_to_gnu): Create the temporary for the return value early, if any.
4518 Create it for a function with copy-in/copy-out parameters if there is
4519 no target; in other cases of copy-in/copy-out, use another temporary.
4520 Push the new binding level lazily. Add and rename local variables.
4521
45222011-03-23 Eric Botcazou <ebotcazou@adacore.com>
4523
4524 * gcc-interface/decl.c (validate_size): Improve comments and tweak
4525 error message.
4526 (set_rm_size): Likewise.
4527
45282011-03-23 Eric Botcazou <ebotcazou@adacore.com>
4529
4530 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
4531 for the padded type built in order to support a specified alignment.
4532 Fix incorrect formatting.
4533
45342011-03-21 Eric Botcazou <ebotcazou@adacore.com>
4535
4536 PR bootstrap/48216
4537 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
4538
45392011-03-21 Eric Botcazou <ebotcazou@adacore.com>
4540
4541 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
4542 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
4543 to the end of the list. Adjust recursive call. Rename local variable.
4544 If REORDER is true, reorder components of the record type.
4545 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
4546 components_to_record and adjust the parameter list.
4547
45482011-03-21 Eric Botcazou <ebotcazou@adacore.com>
4549
4550 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
4551 disabled, use the variable for bounds of loop iteration scheme.
4552
45532011-03-21 Kai Tietz <ktietz@redhat.com>
4554
4555 PR target/12171
4556 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
4557
45582011-03-17 Eric Botcazou <ebotcazou@adacore.com>
4559
4560 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
4561 out whether the expression is read-only. Short-circuit placeholder
4562 case and rename a couple of local variables.
4563
45642011-03-17 Eric Botcazou <ebotcazou@adacore.com>
4565
4566 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
4567 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
4568 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
4569 (convert): Deal with conversions from a smaller form type specially.
4570
45712011-02-14 Eric Botcazou <ebotcazou@adacore.com>
4572
4573 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
4574 its argument, except for the special -I- switch.
4575
45762011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
4577
4578 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
4579 "Ada Issues".
4580
45812011-02-08 Eric Botcazou <ebotcazou@adacore.com>
4582
4583 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
4584
45852011-02-03 Eric Botcazou <ebotcazou@adacore.com>
4586
4587 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
4588 GNAT_FORMAL.
4589 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
4590 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
4591 instead of GNAT_FORMAL. Protect the expression against multiple uses.
4592 Do not generate the check directly, instead instantiate the template
4593 check present in the descriptor.
4594 (make_descriptor_field): Move around.
4595 (build_vms_descriptor32): Build a template check in the POINTER field.
4596 (build_vms_descriptor): Remove useless suffixes.
4597 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
4598
45992011-01-26 Eric Botcazou <ebotcazou@adacore.com>
4600
4601 PR bootstrap/47467
4602 * targext.c: Include target files if IN_RTS is defined.
4603
46042011-01-26 Richard Guenther <rguenther@suse.de>
4605
4606 PR bootstrap/47467
4607 * targext.c: Include config.h.
4608 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
4609 dependency.
4610
46112011-01-04 Pascal Obry <obry@adacore.com>
4612 Eric Botcazou <ebotcazou@adacore.com>
4613
4614 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
4615
46162011-01-04 Eric Botcazou <ebotcazou@adacore.com>
4617
4618 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
4619 end-of-case on the end label and its associated gotos, if any.
4620
46212011-01-04 Eric Botcazou <ebotcazou@adacore.com>
4622
4623 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
4624 expressions of the parameter cache within the statement group of
4625 the CICO mechanism.
4626
46272011-01-04 Olivier Hainque <hainque@adacore.com>
4628 Eric Botcazou <ebotcazou@adacore.com>
4629
4630 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
4631 (set_end_locus_from_node): New function.
4632 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
4633 make and the function end_locus.
4634 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
4635 for the elaboration subprogram.
4636 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
4637 set the end_locus of the expression as well.
4638
46392011-01-04 Eric Botcazou <ebotcazou@adacore.com>
4640
4641 PR ada/47131
4642 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
4643 variables that are referenced in exception handlers volatile.
4644
4645
4646\f
4647Copyright (C) 2011 Free Software Foundation, Inc.
4648
4649Copying and distribution of this file, with or without modification,
4650are permitted in any medium without royalty provided the copyright
4651notice and this notice are preserved.
4652
4653 * gnat_rm.texi: Ramification of pragma Eliminate documentation
4654 - fix bugs in the description of Source_Trace;
4655 - get rid of UNIT_NAME;
4656
4fbad0ba
AC
46572011-08-02 Javier Miranda <miranda@adacore.com>
4658
4659 * exp_ch9.adb
4660 (Build_Dispatching_Requeue): Adding support for VM targets
4661 since we cannot directly reference the Tag entity.
4662 * exp_sel.adb (Build_K): Adding support for VM targets.
4663 (Build_S_Assignment): Adding support for VM targets.
4664 * exp_disp.adb
4665 (Default_Prim_Op_Position): In VM targets do not restrict availability
4666 of predefined interface primitives to compiling in Ada 2005 mode.
4667 (Is_Predefined_Interface_Primitive): In VM targets this service is not
4668 restricted to compiling in Ada 2005 mode.
4669 (Make_VM_TSD): Generate code that declares and initializes the OSD
4670 record. Needed to support dispatching calls through synchronized
4671 interfaces.
4672 * exp_ch3.adb
4673 (Make_Predefined_Primitive_Specs): Enable generation of predefined
4674 primitives associated with synchronized interfaces.
4675 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
4676 primitives associated with synchronized interfaces.
4677
46782011-08-02 Yannick Moy <moy@adacore.com>
4679
4680 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
4681 statements hidden in SPARK if preceded by the HIDE directive
4682 (Parse_Exception_Handlers): mark each exception handler in a sequence of
4683 exception handlers as hidden in SPARK if preceded by the HIDE directive
4684 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
4685 if starting with the HIDE directive
4686 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
4687 starting with the HIDE directive; mark the declarations in a private
4688 part as hidden in SPARK if the private part starts with the HIDE
4689 directive
4690 * restrict.adb, restrict.ads
4691 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
4692 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
4693 argument node belongs to a part which is hidden in SPARK
4694 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
4695 parts in SPARK; protect the possibly costly call to
4696 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
4697 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
4698 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
4699 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
4700 Tok_SPARK_Hide.
4701 (Scan): recognize special comment starting with '#' and followed by
4702 SPARK keyword "hide" as a HIDE directive.
4703
47042011-08-02 Yannick Moy <moy@adacore.com>
4705
4706 * types.ads, erroutc.ads: Minor reformatting.
4707
47082011-08-02 Vincent Celier <celier@adacore.com>
4709
4710 * link.c: Add response file support for cross platforms.
4711
6ff6152d
ES
47122011-08-02 Ed Schonberg <schonberg@adacore.com>
4713
4714 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
4715 in an association, set parent field of copy before partial analysis.
4716 * sem_res.adb (Resolve_Slice): create reference to itype only when
4717 expansion is enabled.
4718
975c6896
YM
47192011-08-02 Yannick Moy <moy@adacore.com>
4720
4721 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
4722 for new flag denoting which subprogram bodies are in ALFA
4723 * restrict.adb, sem_ch7.adb: Update comment
4724 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
4725 sem_ch9.adb, sem_res.adb: Add calls to
4726 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
4727 * sem_ch6.adb (Analyze_Function_Return): add calls to
4728 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
4729 middle of the body, and extended return.
4730 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
4731 False when missing return.
4732 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
4733 to True for subprograms whose spec is in ALFA. Remove later on the flag
4734 on the entity used for a subprogram body when there exists a separate
4735 declaration.
4736 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
4737 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
4738 False, otherwise do nothing.
4739
afc8324d
AC
47402011-08-02 Robert Dewar <dewar@adacore.com>
4741
4742 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
4743
47442011-08-02 Yannick Moy <moy@adacore.com>
4745
4746 * sem_ch4.ads: minor formatting.
4747
2ba431e5
YM
47482011-08-02 Yannick Moy <moy@adacore.com>
4749
4750 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
4751 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
4752 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
4753 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
4754 opt.ads: cleanup of SPARK mode
4755
0f853035
YM
47562011-08-02 Yannick Moy <moy@adacore.com>
4757
4758 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
4759 types.
4760 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
4761 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
4762 * sem_ch3.adb
4763 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
4764 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
4765 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
4766 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
4767 types.
4768 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
4769 non-static range.
4770 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
4771 functions whose return type is not in ALFA.
4772 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
4773 specifications.
4774 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
4775 parameter's type is not in ALFA.
4776 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
4777 types are in ALFA.
4778
d2b10647
ES
47792011-08-02 Ed Schonberg <schonberg@adacore.com>
4780
4781 * sem_ch6 (Analyze_Expression_Function): treat the function as
4782 Inline_Always, and introduce a subprogram declaration for it when it is
4783 not a completion.
4784 * inline.adb (Add_Inlined_Body): recognize bodies that come from
4785 expression functions, so that the back-end can determine whether they
4786 can in fact be inlined.
4787 * sem_util.adb (Is_Expression_Function): predicate to determine whether
4788 a function body comes from an expression function.
4789
c7b9d548
AC
47902011-08-02 Gary Dismukes <dismukes@adacore.com>
4791
4792 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
4793 null exclusions to test Can_Never_Be_Null on the anonymous access types
4794 of the formals rather than testing the formals themselves. Exclude this
4795 check in cases where the Old_Formal is marked as a controlling formal,
4796 to avoid issuing spurious errors for bodies completing dispatching
4797 operations (due to the flag not getting set on controlling access
4798 formals in body specs).
4799 (Find_Corresponding_Spec): When checking full and subtype conformance of
4800 subprogram bodies in instances, pass Designated and E in that order, for
4801 consistency with the expected order of the formals (New_Id followed by
4802 Old_Id).
4803
48042011-08-02 Robert Dewar <dewar@adacore.com>
4805
4806 * sem_ch8.adb: Minor reformatting.
4807
1138cf59
AC
48082011-08-02 Ed Schonberg <schonberg@adacore.com>
4809
4810 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
4811 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
4812 primitive operations of class-wide actuals.
4813
48142011-08-02 Javier Miranda <miranda@adacore.com>
4815
4816 * exp_atag.ads, exp_atag.adb
4817 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
4818 since its value is implicitly passed in argument Typ.
4819 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
4820 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
4821 Build_Common_Dispatching_Select_Statements.
4822
7b9db926
RD
48232011-08-02 Robert Dewar <dewar@adacore.com>
4824
4825 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
4826 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
4827 Minor reformatting.
4828
e8374e7a
AC
48292011-08-02 Robert Dewar <dewar@adacore.com>
4830
4831 * sem_res.adb: Minor reformatting.
4832 * sem_prag.adb: Minor reformatting.
4833
48342011-08-02 Javier Miranda <miranda@adacore.com>
4835
4836 * exp_atag.adb, exp_atags.ads
4837 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
4838 by the tagged type Entity. Required to use this routine in the VM
4839 targets since we do not have available the Tag entity in the VM
4840 platforms.
4841 * exp_ch6.adb
4842 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
4843 Ada.Tags has not been previously loaded.
4844 * exp_ch7.adb
4845 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
4846 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
4847 * sem_aux.adb
4848 (Enclosing_Dynamic_Scope): Add missing support to handle the full
4849 view of enclosing scopes. Required to handle enclosing scopes that
4850 are synchronized types whose full view is a task type.
4851 * exp_disp.adb
4852 (Build_VM_TSDs): Minor code improvement to avoid generating and
4853 analyzing lists with empty nodes.
4854 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
4855 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
4856 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
4857 (Make_Disp_Timed_Select_Body): Add support for VM targets.
4858 (Make_Select_Specific_Data_Table): Add support for VM targets.
4859 (Make_VM_TSD): Generate code to initialize the SSD structure of
4860 the TSD.
4861
48622011-08-02 Yannick Moy <moy@adacore.com>
4863
4864 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
4865 cross-references section in ALI.
4866 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
4867 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
4868 Sub).
4869 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
4870 subprogram or package entity of a node
4871 (Is_Local_Reference_Type): new function returns True for references
4872 selected in local cross-references.
4873 (Lt): function extracted from Lt in Output_References
4874 (Write_Entity_Name): function extracted from Output_References
4875 (Generate_Definition): generate reference with type 'D' for definition
4876 of objects (object declaration and parameter specification), with
4877 appropriate locations and units, for use in local cross-references.
4878 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
4879 references of type 'I' for initialization in object definition.
4880 (Output_References): move part of function Lt and procedure
4881 Write_Entity_Name outside of the body. Ignore references of types 'D'
4882 and 'I' introduced for local cross-references.
4883 (Output_Local_References): new procedure to output the local
4884 cross-references sections.
4885 (Lref_Entity_Status): new array defining whether an entity is a local
4886 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
4887 with 'I' type when initialization expression is present.
4888 * get_scos.adb, get_scos.ads: Correct comments and typos
4889
1f6439e3
AC
48902011-08-02 Javier Miranda <miranda@adacore.com>
4891
4892 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
4893 the JVM target.
4894 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
4895 the JVM target.
4896 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
4897 TSD support.
4898
48992011-08-02 Vincent Celier <celier@adacore.com>
4900
4901 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
4902 (No_Space_Img): New function
4903 (Find_Excluded_Sources): When reading from a file, record the file name
4904 and the line number for each excluded source.
4905 (Mark_Excluded_Sources): When reporting an error, if the excluded
4906 sources were read from a file, include file name and line number in
4907 the error message.
4908
49092011-08-02 Ed Schonberg <schonberg@adacore.com>
4910
4911 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
4912
ab027d28
RD
49132011-08-02 Robert Dewar <dewar@adacore.com>
4914
4915 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
4916
b3b28b0c
JM
49172011-08-02 Javier Miranda <miranda@adacore.com>
4918
4919 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
4920 generation of TSDs to the DOTNET compiler.
4921 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
4922 generation of TSDs to the DOTNET compiler.
4923
9732e886
JM
49242011-08-02 Javier Miranda <miranda@adacore.com>
4925
4926 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
4927 record of all the tagged types declared inside library level package
4928 declarations, library level package bodies or library level subprograms.
4929 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
4930 associated with a given tagged type.
4931 (Build_VM_TSDs): New subprogram.
4932 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
4933 compilation units that are subprograms.
4934 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
4935 compilation units that are package bodies.
4936 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
4937 units that are a package declaration or a package instantiation.
4938 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
4939 reorganization to improve the error generated by the frontend when the
4940 function Ada.Tags.Secondary_Tag is not available.
4941 * rtsfind.ads (RE_Register_TSD): New runtime entity.
4942 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
4943
e526d0c7
AC
49442011-08-02 Javier Miranda <miranda@adacore.com>
4945
4946 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
4947
49482011-08-02 Robert Dewar <dewar@adacore.com>
4949
4950 * s-imenne.ads: Minor reformatting.
4951
49522011-08-02 Robert Dewar <dewar@adacore.com>
4953
4954 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
4955 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
4956 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
4957
49582011-08-02 Robert Dewar <dewar@adacore.com>
4959
4960 * einfo.ads (Materialize_Entity): Document this is only for renamings
4961 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
4962 required debug information in the case where we transform the object
4963 declaration into a renaming declaration.
4964 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
4965 object
4966 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
4967 Materialize_Entity.
4968
5b1e6aca
RD
49692011-08-02 Robert Dewar <dewar@adacore.com>
4970
4971 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
4972 Suppress_Init_Procs.
4973 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
4974 Suppress_Initialization/Initialization_Suppressed.
4975 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
4976 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
4977 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
4978 * sem_prag.adb: New processing for pragma Suppress_Initialization.
4979
5ad4969d
RD
49802011-08-02 Robert Dewar <dewar@adacore.com>
4981
4982 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
4983 Minor reformatting.
4984
8c4ee6f5
AC
49852011-08-02 Ed Schonberg <schonberg@adacore.com>
4986
4987 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
4988 only have inheritable classwide pre/postconditions.
4989
49902011-08-02 Javier Miranda <miranda@adacore.com>
4991
4992 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
4993 * rtsfind.ads (RE_Check_TSD): New runtime entity.
4994 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
4995 checks if the external tag of a type is the same as the external tag
4996 of some other declaration.
4997
0b3d16c0
AC
49982011-08-02 Thomas Quinot <quinot@adacore.com>
4999
5000 * s-taskin.ads: Minor reformatting.
5001
50022011-08-02 Emmanuel Briot <briot@adacore.com>
5003
5004 * g-comlin.adb (Display_Help): swap the order in which it prints the
5005 short help and the general usage.
5006
50072011-08-02 Ed Schonberg <schonberg@adacore.com>
5008
5009 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
5010 the aspect declarations and attach them to the generic copy for
5011 subsequent analysis.
5012 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
5013 declarations of the generic tree to the new subprogram declarations.
5014 * sem_attr.adb (Check_Precondition_Postcondition): recognize
5015 conditions that apply to a subprogram instance.
5016
50172011-08-02 Robert Dewar <dewar@adacore.com>
5018
5019 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
5020
50212011-08-02 Ed Schonberg <schonberg@adacore.com>
5022
5023 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
5024 private type with a tagged full view is not derived in the immediate
5025 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
5026
4637729f
AC
50272011-08-02 Robert Dewar <dewar@adacore.com>
5028
5029 * exp_ch4.adb: Minor reformatting.
5030
50312011-08-02 Ed Schonberg <schonberg@adacore.com>
5032
5033 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
5034 Ada2012 iterator, the loop will be rewritten during expansion into a
5035 while loop with a cursor and an element declaration. Do not analyze the
5036 body in this case, because if the container is for indefinite types the
5037 actual subtype of the elements will only be determined when the cursor
5038 declaration is analyzed.
5039
50402011-08-02 Arnaud Charlet <charlet@adacore.com>
5041
5042 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
5043 size/alignment related attributes in CodePeer_Mode.
5044
50452011-08-02 Gary Dismukes <dismukes@adacore.com>
5046
5047 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
5048 Prepend_Element, since this can result in the operation getting the
5049 wrong slot in the full type's dispatch table if the full type has
5050 inherited operations. The incomplete type's operation will get added
5051 to the proper position in the full type's primitives
5052 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
5053 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
5054 dispatching operations, since there are cases where nonprimitive
5055 subprograms can get added to the list of incomplete dependents (such
5056 as subprograms in nested packages).
5057 * sem_ch6.adb (Process_Formals): First, remove test for being in a
5058 private part when determining whether to add a primitive with a
5059 parameter of a tagged incomplete type to the Private_Dependents list.
5060 Such primitives can also occur in the visible part, and should not have
5061 been excluded from being private dependents.
5062 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
5063 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
5064 list of a Taft-amendment incomplete type is a primitive before issuing
5065 an error that the full type must appear in the same unit. There are
5066 cases where nonprimitives can be in the list (such as subprograms in
5067 nested packages).
5068 * sem_disp.adb (Derives_From): Use correct condition for checking that
5069 a formal's type is derived from the type of the corresponding formal in
5070 the parent subprogram (the condition was completely wrong). Add
5071 checking that was missing for controlling result types being derived
5072 from the result type of the parent operation.
5073
4c60de0c
YM
50742011-08-02 Yannick Moy <moy@adacore.com>
5075
5076 * errout.adb (First_Node): minor renaming
5077 * restrict.adb (Check_Formal_Restriction): put restriction warning on
5078 first node.
5079
f5afb270
AC
50802011-08-02 Yannick Moy <moy@adacore.com>
5081
5082 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
5083 before accessing operands.
5084 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
5085 decide whether an initialization expression respects SPARK rules, as
5086 the plain node is the expanded one. This allows for more valid warnings
5087 to be issued.
5088 * gnat_rm.texi: Minor update.
5089
50902011-08-02 Arnaud Charlet <charlet@adacore.com>
5091
5092 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
5093 previous change.
5094
50952011-08-02 Robert Dewar <dewar@adacore.com>
5096
5097 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
5098
50992011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5100
5101 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
5102 loop statements and the element renaming declaration with a block when
5103 the element type is controlled.
5104
51052011-08-02 Yannick Moy <moy@adacore.com>
5106
5107 * sinfo.ads: Minor formatting.
5108
51092011-08-02 Ed Schonberg <schonberg@adacore.com>
5110
5111 * sem_aggr.adb (Add_Association): if the association has a box and no
5112 expression, use the Sloc of the aggregate itself for the new
5113 association.
5114 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
5115 the Original_Node.
5116
db72f10a
AC
51172011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5118
5119 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
5120 When a container is provided via a function call, generate a renaming
5121 of the function result. This avoids the creation of a transient scope
5122 and the premature finalization of the container.
5123 * exp_ch7.adb (Is_Container_Cursor): Removed.
5124 (Wrap_Transient_Declaration): Remove the supression of the finalization
5125 of the list controller when the declaration denotes a container cursor,
5126 it is not needed.
5127
51282011-08-02 Yannick Moy <moy@adacore.com>
5129
5130 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
5131 node is from source, instead of the original node being from source.
5132 * sem_aggr.adb
5133 (Resolve_Array_Aggregate): refine the check for a static expression, to
5134 recognize also static ranges
5135 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
5136 Array_Type_Declaration): postpone the test for the type being a subtype
5137 mark after the type has been resolved, so that component-selection and
5138 expanded-name are discriminated.
5139 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
5140 to distinguish the case of an iteration scheme, so that an error is
5141 issed on a non-static range in SPARK except in an iteration scheme.
5142 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
5143 In_Iter_Schm = True.
5144 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
5145 user-defined operators so that they are allowed in renaming
5146 * sem_ch8.adb
5147 (Find_Selected_Component): refine the check for prefixing of operators
5148 so that they are allowed in renaming. Move the checks for restrictions
5149 on selector name after analysis discriminated between
5150 component-selection and expanded-name.
5151 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
5152 concatenation argument of string type if it is static.
5153 * sem_util.adb, sem_util.ads
5154 (Check_Later_Vs_Basic_Declarations): add a new function
5155 Is_Later_Declarative_Item to decice which declarations are allowed as
5156 later items, in the two different modes Ada 83 and SPARK. In the SPARK
5157 mode, add that renamings are considered as later items.
5158 (Enclosing_Package): new function to return the enclosing package
5159 (Enter_Name): correct the rule for homonyms in SPARK
5160 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
5161 from source (result of expansion) to avoid issuing wrong warnings.
5162
51632011-08-02 Ed Schonberg <schonberg@adacore.com>
5164
5165 * errout.adb: On anything but an expression First_Node returns its
5166 argument.
5167
23685ae6
AC
51682011-08-02 Pascal Obry <obry@adacore.com>
5169
5170 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
5171
51722011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5173
5174 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
5175 Set the associated loop as the related expression of internally
5176 generated cursors.
5177 * exp_ch7.adb (Is_Container_Cursor): New routine.
5178 (Wrap_Transient_Declaration): Supress the finalization of the list
5179 controller when the declaration denotes a container cursor.
5180
51812011-08-02 Yannick Moy <moy@adacore.com>
5182
5183 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
5184 command line now.
5185 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
5186 expression is a simple expression. This check cannot be performed in
5187 the semantics, so just drop it.
5188 (P_Index_Or_Discriminant_Constraint): move check that the index or
5189 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
5190 semantics. Other cases were previously checked in the semantics.
5191 * par-ch4.adb (P_Name): move checks that a selector name is not
5192 character literal or an operator symbol to Find_Selected_Component in
5193 the semantics
5194 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
5195 declarations are not placed after later declarations in a separate
5196 procedure in Sem_Util (possibly not the best choice?), to be used both
5197 during parsing, for Ada 83 mode, and during semantic analysis, for
5198 SPARK mode.
5199 * par-endh.adb (Check_End): move check that end label is not missing
5200 to Process_End_Label in the semantics
5201 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
5202 the special case for SPARK restriction
5203 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
5204 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
5205 parameter Force to issue the error message even on internal node (used
5206 for generated end label). Call Check_Restriction to check when an error
5207 must be issued. In SPARK mode, issue an error message even if the
5208 restriction is not set.
5209 (Check_Restriction): new procedure with an additional out parameter to
5210 inform the caller that a message has been issued
5211 * sem_aggr.adb: Minor modification of message
5212 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
5213 instead of issuing an error message directly
5214 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
5215 declarations are not placed after later declarations, by calling
5216 Check_Later_Vs_Basic_Declarations
5217 (Analyze_Subtype_Declaration): move here the check that an index or
5218 discriminant constraint must be a subtype mark. Change the check that
5219 a subtype of String must start at one so that it works on subtype marks.
5220 * sem_ch4.adb (Analyze_Call): move here the check that a named
5221 association cannot follow a positional one in a call
5222 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
5223 instead of issuing an error message directly
5224 * sem_ch8.adb (Find_Selected_Component): move here the check that a
5225 selector name is not a character literal or an operator symbol. Move
5226 here the check that the prefix of an expanded name cannot be a
5227 subprogram or a loop statement.
5228 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
5229 procedure called from parsing and semantics to check that basic
5230 declarations are not placed after later declarations
5231 (Process_End_Label): move here the check that end label is not missing
5232
52332011-08-02 Arnaud Charlet <charlet@adacore.com>
5234
5235 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
5236 representation clause in codepeer mode, since it confuses CodePeer and
5237 does not bring useful info.
5238
52392011-08-02 Ed Falis <falis@adacore.com>
5240
5241 * init.c: initialize fp hw on MILS.
5242
52432011-08-02 Ed Schonberg <schonberg@adacore.com>
5244
5245 * errout.adb (First_Node): for bodies, return the node itself (small
5246 optimization). For other nodes, do not check source_unit if the node
5247 comes from Standard.
5248
d2d9cc22
AC
52492011-08-02 Robert Dewar <dewar@adacore.com>
5250
5251 * exp_ch3.adb: Minor comment additions.
5252 * sem_ch13.adb: Minor reformatting.
5253
52542011-08-02 Pascal Obry <obry@adacore.com>
5255
5256 * make.adb, makeutl.adb: Removes some superfluous directory separator.
5257
a01b9df6
AC
52582011-08-02 Robert Dewar <dewar@adacore.com>
5259
5260 * sem_attr.adb: Minor reformatting.
5261
52622011-08-02 Robert Dewar <dewar@adacore.com>
5263
5264 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
5265 (Has_Default_Component_Value): Removed
5266 * einfo.ads Comment updates
5267 (Has_Default_Aspect): Replaces Has_Default_Value
5268 (Has_Default_Component_Value): Removed
5269 * exp_ch13.adb
5270 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
5271 * exp_ch3.adb
5272 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
5273 (Get_Simple_Init_Val): Handle Default_Value aspect
5274 (Needs_Simple_Initialization): Handle Default_Value aspect
5275 * exp_ch3.ads: Needs_Simple_Initialization
5276 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
5277 * par-prag.adb (Pragma_Default[_Component]Value) Removed
5278 * sem_ch13.adb
5279 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
5280 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
5281 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
5282
52832011-08-02 Ed Schonberg <schonberg@adacore.com>
5284
5285 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
5286 package containing iteration primitives.
5287 exp_ch5.adb (Expand_Iterator_Loop): ditto.
5288
75c90775
AC
52892011-08-02 Ed Schonberg <schonberg@adacore.com>
5290
5291 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
5292 "of", pre-analyze expression in case it is a function call with
5293 finalization actions that must be placed ahead of the loop.
5294 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
5295 on an Ada2012 iterator, insert them ahead of the rewritten loop.
5296
52972011-08-02 Geert Bosch <bosch@adacore.com>
5298
5299 * cstand.adb (Create_Float_Types): Only consider C's long double for
5300 Long_Long_Float, in addition to double.
5301
ded8909b
AC
53022011-08-02 Robert Dewar <dewar@adacore.com>
5303
5304 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
5305 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
5306 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
5307 Minor reformatting.
5308
53092011-08-02 Ed Schonberg <schonberg@adacore.com>
5310
5311 * sem_attr.adb: handle properly 'Result when it is a prefix of an
5312 indexed component.
5313
53142011-08-02 Javier Miranda <miranda@adacore.com>
5315
5316 * einfo.ads, einfo.adb
5317 (Original_Access_Type): Move this attribute to Node26 since there was
5318 an undocumented use of Node21 in E_Access_Subprogram_Type entities
5319 which causes conflicts and breaks the generation of the .NET compiler.
5320 (Interface_Name): Add missing documentation on JGNAT only uses of
5321 this attribute.
5322
70c34e1c
AC
53232011-08-02 Geert Bosch <bosch@adacore.com>
5324
5325 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
5326 (Find_Back_End_Float_Type): Likewise
5327 (Create_Back_End_Float_Types): Likewise
5328 (Create_Float_Types): Likewise
5329 (Register_Float_Type): Likewise
5330 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
5331 Nlist and split out type selection in new local Find_Base_Type function.
5332 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
5333 Nlist
5334 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
5335
53362011-08-02 Robert Dewar <dewar@adacore.com>
5337
5338 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
5339 alpha order).
5340 * opt.ads: Minor comment change.
5341 * sem_ch12.adb: Minor code reorganization.
5342
b715bc59
AC
53432011-08-02 Gary Dismukes <dismukes@adacore.com>
5344
5345 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
5346 subtype's list of rep items to the list on the full subtype in the case
5347 where the lists are the same.
5348
53492011-08-02 Geert Bosch <bosch@adacore.com>
5350
5351 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
5352 using the one from System.Strings, which also deallocates all strings.
5353
002bdd68
AC
53542011-08-02 Geert Bosch <bosch@adacore.com>
5355
5356 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
5357 function.
5358 * gcc-interface/Make-lang.in: Update dependencies.
5359
53602011-08-02 Olivier Hainque <hainque@adacore.com>
5361
5362 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
5363 end_locus.
5364
499769ec
AC
53652011-08-02 Javier Miranda <miranda@adacore.com>
5366
5367 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
5368 associated with anonymous access to subprograms.
5369
53702011-08-02 Geert Bosch <bosch@adacore.com>
5371
5372 * opt.ads
5373 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
5374 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
5375 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
5376 (Add_Symbol_Definition): Move to switch-c.adb
5377 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
5378 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
5379 (Add_Symbol_Definition): Move to switch-c.adb.
5380 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
5381 * sem_warn.adb
5382 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
5383 Move to warnsw.adb.
5384 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
5385 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
5386 Move to warnsw.adb.
5387 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
5388 (Add_Symbol_Definition): Moved from Prepcomp.
5389 * switch-c.ads: Update copyright notice. Use String_List instead of
5390 Argument_List, removing dependency on System.OS_Lib.
5391
aa1e353a
AC
53922011-08-02 Yannick Moy <moy@adacore.com>
5393
5394 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
5395 mode on initialization expression which does not respect SPARK
5396 restrictions.
5397 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
5398 if the tree referenced by its argument represents an initialization
5399 expression in SPARK, suitable for initializing an object in an object
5400 declaration.
5401
54022011-08-02 Javier Miranda <miranda@adacore.com>
5403
5404 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
5405 internally generated access to subprogram with its associated protected
5406 subprogram type.
5407 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
5408
15b682ca
GB
54092011-08-02 Geert Bosch <bosch@adacore.com>
5410
5411 * cstand.adb (Register_Float_Type): Print information about type to
5412 register, if the Debug_Flag_Dot_B is set.
5413 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
5414 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
5415 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
5416 with a requested precision of more than Max_Digits digits and no more
5417 than Max_Base_Digits digits, if a range specification is present and the
5418 Predefined_Float_Types list has a suitable type to derive from.
5419 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
5420 case of type completion with pragma Import
5421 * sem_prag.adb
5422 (Process_Import_Predefined_Type): Processing to complete a type
5423 with pragma Import. Currently supports floating point types only.
5424 (Set_Convention_From_Pragma): Do nothing without underlying type.
5425 (Process_Convention): Guard against absence of underlying type,
5426 which may happen when importing incomplete types.
5427 (Process_Import_Or_Interface): Handle case of importing predefined
5428 types. Tweak error message.
5429
f8726f2b
AC
54302011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5431
5432 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
5433 functions to previous change. Reorganize code slightly.
5434
54352011-08-02 Geert Bosch <bosch@adacore.com>
5436
5437 * back_end.ads (Register_Type_Proc): New call back procedure type for
5438 allowing the back end to provide information about available types.
5439 (Register_Back_End_Types): New procedure to register back end types.
5440 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
5441 available types.
5442 * cstand.adb (Back_End_Float_Types): New list for floating point types
5443 supported by the back end.
5444 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
5445 (Copy_Float_Type): New procedure to make new copies of predefined types.
5446 (Register_Float_Type): New call back procedure to populate the BEFT list
5447 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
5448 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
5449 (Create_Float_Types): New procedure to create entities for floating
5450 point types predefined in Standard, and put these and any remaining
5451 BEFTs on the Predefined_Float_Types list.
5452 * stand.ads (Predefined_Float_Types): New list for predefined floating
5453 point types that do not have declarations in package Standard.
5454
feecad68
AC
54552011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5456
5457 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
5458 entity node for the unit containing the parameter.
5459 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
5460 (Add_Inlined_Subprogram): Likewise.
5461 * gcc-interface/Make-lang.in: Update dependencies.
5462
54632011-08-02 Thomas Quinot <quinot@adacore.com>
5464
5465 * s-stusta.adb (Print): Make sure Pos is always initialized to a
5466 suitable value.
5467
12f0c50c
AC
54682011-08-02 Geert Bosch <bosch@adacore.com>
5469
5470 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
5471
54722011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5473
5474 * sem_type.adb (Covers): Move trivial case to the top and reuse the
5475 computed value of Base_Type.
5476
54772011-08-02 Yannick Moy <moy@adacore.com>
5478
5479 * restrict.adb (Check_Restriction): issue an error for any use of
5480 class-wide, even if the No_Dispatch restriction is not set.
5481 * sem_aggr.adb: Correct typos in comments and messages in formal mode
5482 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
5483 when completing a private extension, the type named in the private part
5484 is not the same as that named in the visible part.
5485 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
5486 of an inherited primitive operations of a tagged type or type extension
5487 that returns the tagged type.
5488 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
5489 function which returns True for an implicit operation inherited by the
5490 derived type declaration for the argument type.
5491 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
5492 order.
5493
fb86fe11
ES
54942011-08-02 Ed Schonberg <schonberg@adacore.com>
5495
5496 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
5497 Process_Bounds, to perform analysis with expansion of a range or an
5498 expression that is the iteration scheme for a loop.
5499 (Analyze_Iterator_Specification): If domain of iteration is given by a
5500 function call with a controlled result, as is the case if call returns
5501 a predefined container, ensure that finalization actions are properly
5502 generated.
5503 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
5504
62be5d0a
JM
55052011-08-02 Javier Miranda <miranda@adacore.com>
5506
5507 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
5508 * gcc-interface/Make-lang.in: Update dependencies.
5509
55102011-08-02 Javier Miranda <miranda@adacore.com>
5511
5512 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
5513 determine if the analysis is performed using N or Original_Node (N).
5514 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
5515 functionality of routine Is_Variable avoids code duplication.
5516 * checks.adb (Determine_Range): Handle temporaries generated by
5517 Remove_Side_Effects.
5518
55192011-08-02 Javier Miranda <miranda@adacore.com>
5520
5521 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
5522 expansion of the condition. Required since the previous analysis was
5523 done with expansion disabled (see Resolve_Quantified_Expression) and
5524 hence checks were not inserted and record comparisons have not been
5525 expanded.
5526
a20f4389
AC
55272011-08-02 Ed Falis <falis@adacore.com>
5528
5529 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
5530 Update header.
5531
55322011-08-02 Bob Duff <duff@adacore.com>
5533
5534 * opt.ads: Minor comment fix.
5535
55362011-08-02 Bob Duff <duff@adacore.com>
5537
5538 * sem_ch12.adb (Analyze_Package_Instantiation,
5539 Analyze_Subprogram_Instantiation): Turn off style checking while
5540 analyzing an instance. Whatever style checks that apply to the generic
5541 unit should apply, so it makes no sense to apply them in an instance.
5542 This was causing trouble when compiling an instance of a runtime
5543 unit that violates the -gnatyO switch.
5544 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
5545 one of the two case statements, causing spurious errors.
5546
55472011-08-02 Robert Dewar <dewar@adacore.com>
5548
5549 * uname.adb: Minor reformatting.
5550 * gnatcmd.adb: Minor reformatting.
5551 * exp_attr.adb: Minor reformatting.
5552
90878b12
AC
55532011-08-02 Ed Schonberg <schonberg@adacore.com>
5554
5555 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
5556 No_Dispatching_Calls, do not look for the Assign primitive, because
5557 predefined primitives are not created in this case.
5558
55592011-08-02 Bob Duff <duff@adacore.com>
5560
5561 * stylesw.ads: Minor comment fixes.
5562
55632011-08-02 Robert Dewar <dewar@adacore.com>
5564
5565 * freeze.adb (Add_To_Result): New procedure.
5566
55672011-08-02 Jose Ruiz <ruiz@adacore.com>
5568
5569 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
5570 time, if the specific run-time routines for handling streams of strings
5571 are not available, use the default mechanism.
5572
55732011-08-02 Arnaud Charlet <charlet@adacore.com>
5574
5575 * s-regpat.ads: Fix typo.
5576
55772011-08-02 Vincent Celier <celier@adacore.com>
5578
5579 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
5580 not null, call it to create the in memory config project file without
5581 parsing an existing default config project file.
5582
55832011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5584
5585 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
5586
55872011-08-02 Ed Schonberg <schonberg@adacore.com>
5588
5589 * sem_elim.adb: an abstract subprogram does not need an eliminate
5590 pragma for its descendant to be eliminable.
5591
55922011-08-02 Ed Falis <falis@adacore.com>
5593
5594 * init.c: revert to handling before previous checkin for VxWorks
5595 * s-intman-vxworks.adb: delete unnecessary declarations related to
5596 using Ada interrupt facilities for handling signals.
5597 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
5598 * s-intman-vxworks.ads: Import __gnat_install_handler as
5599 Initialize_Interrupts.
5600 * s-taprop-vxworks.adb: Delete Signal_Mask.
5601 (Abort_Handler): change construction of mask to unblock exception
5602 signals.
5603
273adcdf
AC
56042011-08-02 Jerome Guitton <guitton@adacore.com>
5605
5606 * a-except-2005.adb (Raise_From_Signal_Handler): Call
5607 Debug_Raise_Exception before propagation starts.
5608
56092011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5610
5611 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
5612 to Restriction_Check_Required.
5613 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
5614 * sem_res.adb (Resolve_Call): Likewise.
5615 * sem_attr.adb (Check_Stream_Attribute): Likewise.
5616
56172011-08-02 Bob Duff <duff@adacore.com>
5618
5619 * stylesw.ads: Update comment.
5620 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
5621 * errout.ads: Remove obsolete comment.
5622
56232011-08-02 Javier Miranda <miranda@adacore.com>
5624
5625 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
5626 (Set_Is_Safe_To_Reevaluate): new procedure.
5627 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
5628 assignment is allowed on safe-to-reevaluate variables.
5629 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
5630 temporary created to remove side effects in expressions that use
5631 the secondary stack as safe-to-reevaluate.
5632 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
5633 variables that are not true constants.
5634
6320f5e1
AC
56352011-08-02 Robert Dewar <dewar@adacore.com>
5636
5637 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
5638 sem_res.adb, sem_ch6.adb: Minor reformatting.
5639
56402011-08-02 Jerome Guitton <guitton@adacore.com>
5641
5642 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
5643
2fe829ae
ES
56442011-08-02 Ed Schonberg <schonberg@adacore.com>
5645
5646 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
5647 not set Overridden_Operation if subprogram is an initialization
5648 procedure.
5649
e24329cd
YM
56502011-08-02 Yannick Moy <moy@adacore.com>
5651
5652 * par-ch6.adb: Correct obsolete name in comments
5653 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
5654 which takes two message arguments (existing function takes one), with
5655 second message used for continuation.
5656 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
5657 block statements that originate from a source block statement, not
5658 generated block statements
5659 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
5660 symmetry with procedure case
5661 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
5662 function to issue an error in formal mode if a package specification
5663 contains more than one tagged type or type extension.
5664 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
5665 parameters matching formals of tagged types are objects (or ancestor
5666 type conversions of objects), not general expressions. Issue an error
5667 on view conversions that are not involving ancestor conversion of an
5668 extended type.
5669 (Resolve_Type_Conversion): in formal mode, issue an error on the
5670 operand of an ancestor type conversion which is not an object
5671 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
5672 procedure so that it works also for actuals of function calls
5673 (Is_Actual_Tagged_Parameter): new function which determines if its
5674 argument is an actual parameter of a formal of tagged type in a
5675 subprogram call
5676 (Is_SPARK_Object_Reference): new function which determines if the tree
5677 referenced by its argument represents an object in SPARK
5678
176dadf6
AC
56792011-08-02 Robert Dewar <dewar@adacore.com>
5680
5681 * sem_ch3.adb: Minor reformatting
5682 Minor comment addition
5683 Minor error msg text change
5684
56852011-08-02 Javier Miranda <miranda@adacore.com>
5686
5687 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
5688 function. Used to be more precise when we generate a variable plus one
5689 assignment to remove side effects in the evaluation of the Bound
5690 expressions.
5691 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
5692 of the bound expression to force its re-analysis and thus expand the
5693 associated transient scope (if required). Code cleanup replacing the
5694 previous code that declared the constant entity by an invocation to
5695 routine Force_Evaluation which centralizes this work in the frontend.
5696
d8b962d8
AC
56972011-08-02 Robert Dewar <dewar@adacore.com>
5698
5699 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
5700 (Base_Type): Now uses improved Is_Base_Type function
5701 * einfo.ads (Base_Type): Inline this function
5702
57032011-08-02 Robert Dewar <dewar@adacore.com>
5704
5705 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
5706 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
5707
57082011-08-02 Arnaud Charlet <charlet@adacore.com>
5709
5710 * gcc-interface/Make-lang.in: Update dependencies.
5711 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
5712 targets.
5713
57142011-08-02 Yannick Moy <moy@adacore.com>
5715
5716 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
5717 non-simple expression used in delta constraint
5718 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
5719 index constraint which is not a subtype mark
5720 * par.adb: With and use Restrict
5721 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
5722 mode on component type which is not a subtype mark and default
5723 expression on component
5724 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
5725 of string which does not have a lower index bound equal to 1
5726 (Array_Type_Declaration): issue an error in formal mode on index or
5727 component type which is not a subtype mark, and on aliased keyword on
5728 component
5729 (Derived_Type_Declaration): issue an error in formal mode on interface,
5730 limited or abstract type
5731 (Record_Type_Declaration): issue an error in formal mode on interface
5732 (Record_Type_Definition): issue an error in formal mode on tagged types
5733 and type extensions not declared in the specification of a library unit
5734 package; on null non-tagged record; on variant part
5735
57362011-08-02 Vincent Celier <celier@adacore.com>
5737
5738 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
5739 not declared for qualified library project when Library_Name is not
5740 declared, but Library_Dir is.
5741
57422011-08-02 Robert Dewar <dewar@adacore.com>
5743
5744 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
5745 pragmas (affects aspects [Component_]Default_Value
5746 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
5747 component type for the resolution
5748
f96b2d85
AC
57492011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5750
5751 * einfo.adb (Base_Type): Tune implementation for speed.
5752
57532011-08-02 Robert Dewar <dewar@adacore.com>
5754
5755 * freeze.adb: Minor reformatting.
5756
8b3c6430
AC
57572011-08-02 Thomas Quinot <quinot@adacore.com>
5758
5759 * scos.ads: Update comments.
5760
57612011-08-02 Ed Schonberg <schonberg@adacore.com>
5762
5763 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
5764 base type, because the parent may be a subtype of a private type whose
5765 convention is established in a private part.
5766
57672011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5768
5769 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
5770 statement in a block when the expansion of the return expression has
5771 created a finalization chain.
5772 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
5773 with the parent node.
5774 Add N_Extended_Return_Statement to handle the case where a transient
5775 object declaration appears in the Return_Object_Declarations list of
5776 an extended return statement.
5777
57782011-08-02 Matthew Gingell <gingell@adacore.com>
5779
5780 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
5781 unused parameter 'name'.
5782
57832011-08-02 Ed Schonberg <schonberg@adacore.com>
5784
5785 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
5786 inherited operation, check whether its alias, which is the source
5787 operastion that it renames, has been marked eliminated.
5788
cae81f17
JM
57892011-08-02 Javier Miranda <miranda@adacore.com>
5790
5791 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
5792 in-mode parameter whose type is an access type since it can be used to
5793 modify its designated object. Enforce code that handles as safe an
5794 access type that is not access-to-constant but it is the result of a
5795 previous removal of side-effects.
5796 (Remove_Side_Effects): Minor code reorganization of cases which require
5797 no action. Done to incorporate documentation on new cases uncovered
5798 working in this ticket: no action needed if this routine was invoked
5799 too early and the nodes are not yet decorated.
5800 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
5801 to routine Remove_Side_Effects by calls to Force_Evaluation since they
5802 were issued with actuals that are implicitly provided by
5803 Force_Evaluation.
5804
218e6dee
RD
58052011-08-02 Robert Dewar <dewar@adacore.com>
5806
5807 * sem_ch3.adb, sem_res.adb: Minor reformatting.
5808
7a489a2b
AC
58092011-08-02 Yannick Moy <moy@adacore.com>
5810
5811 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
5812 to issue an error in formal mode on attribute not supported in this mode
5813 (Analyze_Attribute): issue errors on standard attributes not supported
5814 in formal mode.
5815 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
5816 comment, and issue error in formal mode on modulus which is not a power
5817 of 2.
5818 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
5819 range.
5820 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
5821 subtype mark.
5822 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
5823 operator on modular type (except 'not').
5824
58252011-08-02 Robert Dewar <dewar@adacore.com>
5826
5827 * gnat_rm.texi: Minor reformatting.
5828
cb7fa356
AC
58292011-08-02 Arnaud Charlet <charlet@adacore.com>
5830
5831 * s-osinte-linux.ads: Minor comment update and reformatting.
5832 * i-cexten.ads: Make this unit pure, as for its parent.
5833 Will allow its usage in more contexts if needed.
5834
58352011-08-02 Robert Dewar <dewar@adacore.com>
5836
5837 * s-utf_32.ads: Minor comment fix.
5838
58392011-08-02 Ed Schonberg <schonberg@adacore.com>
5840
5841 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
5842 operation of a tagged synchronized type, handle the case where the
5843 controlling argument is overloaded.
5844
58452011-08-02 Yannick Moy <moy@adacore.com>
5846
5847 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
5848 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
5849 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
5850 SPARK mode and formal verification mode on processing SPARK restriction
5851 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
5852 requiring consistency checking.
5853
5cc9353d
RD
58542011-08-02 Robert Dewar <dewar@adacore.com>
5855
5856 * sem_res.adb: Minor reformatting.
5857
e51537ff
RD
58582011-08-02 Robert Dewar <dewar@adacore.com>
5859
5860 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5861 a-cforse.ads: Remove unneeded with of Ada.Containers
5862 Remove commented out pragma Inline's
5863 Move specifications of new subprograms to the actual specs
5864
83fa09c5
AC
58652011-08-02 Yannick Moy <moy@adacore.com>
5866
5867 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5868 a-cforse.ads: Update comments.
5869
58702011-08-02 Ed Schonberg <schonberg@adacore.com>
5871
5872 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
5873
d11cfaf8
RD
58742011-08-02 Robert Dewar <dewar@adacore.com>
5875
5876 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5877 a-cforse.ads, a-cofove.ads: Minor reformatting.
5878
300b98bb
AC
58792011-08-02 Claire Dross <dross@adacore.com>
5880
5881 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
5882 a-cofove.ads: Add comments.
5883
58842011-08-02 Yannick Moy <moy@adacore.com>
5885
5886 * gnat_rm.texi: Document formal containers.
5887
58882011-08-02 Emmanuel Briot <briot@adacore.com>
5889
5890 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
5891 are empty sections.
5892
19fb051c
AC
58932011-08-02 Robert Dewar <dewar@adacore.com>
5894
5895 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
5896 reformatting.
5897
58982011-08-02 Robert Dewar <dewar@adacore.com>
5899
5900 * aspects.adb: New aspects Default_Value and Default_Component_Value
5901 New format of Aspect_Names table checks for omitted entries
5902 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
5903 handling of boolean aspects for derived types.
5904 New aspects Default_Value and Default_Component_Value
5905 New format of Aspect_Names table checks for omitted entries
5906 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
5907 (Has_Default_Value): New flag
5908 (Has_Default_Component_Value): New flag
5909 (Has_Default_Value): New flag
5910 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
5911 table.
5912 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
5913 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
5914 Default_Value and Default_Component_Value
5915 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
5916 New aspects Default_Value and Default_Component_Value
5917 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
5918 * sprint.adb: Print N_Aspect_Specification node when called from gdb
5919
59202011-08-02 Vincent Celier <celier@adacore.com>
5921
5922 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
5923 inherit library kind.
5924
59252011-08-02 Ed Schonberg <schonberg@adacore.com>
5926
5927 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
5928 Minor reformatting.
5929
59302011-08-02 Robert Dewar <dewar@adacore.com>
5931
5932 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
5933
5f7747af
AC
59342011-08-02 Yannick Moy <moy@adacore.com>
5935
5936 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
5937
59382011-08-02 Robert Dewar <dewar@adacore.com>
5939
5940 * impunit.adb: Add comment.
5941
a5fe697b
AC
59422011-08-02 Yannick Moy <moy@adacore.com>
5943
5944 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
5945 qualification of aggregates in formal mode
5946 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
5947 another aggregate
5948 (Resolve_Aggregate): complete the test that an aggregate is adequately
5949 qualified in formal mode
5950
59512011-08-02 Pascal Obry <obry@adacore.com>
5952
5953 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
5954 * mlib-prj.adb: Supress warning when compiling binder generated file.
5955 (Build_Library): Supress all warnings when compiling the binder
5956 generated file.
5957
bd65a2d7 59582011-08-02 Yannick Moy <moy@adacore.com>
d4487611 5959
bd65a2d7
AC
5960 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
5961 from here...
5962 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
5963 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
5964 Add with/use clauses to make Check_Formal_Restriction visible
5965
59662011-08-02 Ed Schonberg <schonberg@adacore.com>
5967
5968 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
5969 in-parameters when type of the generic formal is private in the generic
5970 spec and non-private in the body.
5971
59722011-08-02 Claire Dross <dross@adacore.com>
5973
5974 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
5975 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
5976 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
5977 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
5978
59792011-08-02 Robert Dewar <dewar@adacore.com>
5980
5981 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
5982 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
5983
bd434b3f
YM
59842011-08-02 Yannick Moy <moy@adacore.com>
5985
5986 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
5987 formal mode
5988 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
5989 matching static array bounds, taking into account the special case of
5990 string literals
5991 * sem_ch3.adb: Typo in comment.
5992
fe5d3068
YM
59932011-08-02 Yannick Moy <moy@adacore.com>
5994
5995 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
5996 which issues an error in formal mode if its argument node is originally
5997 from source
5998 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
5999 has a discriminant specification so that it does not include the case
6000 of derived types
6001 (Derived_Type_Declaration): move here the test that a derived type has a
6002 discriminant specification
6003 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
6004 first element of a component association before accessing its choices
6005 (presence of component association is not enough)
6006 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
6007 declaration is a library item before accessing the next element in a
6008 list, as library items are not member of lists
6009 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
6010 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
6011 Check_Formal_Restriction whenever possible.
6012
b60a3f26
AC
60132011-08-02 Ed Schonberg <schonberg@adacore.com>
6014
6015 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
6016 reference when needed.
6017
60182011-08-02 Bob Duff <duff@adacore.com>
6019
6020 * gnat_ugn.texi: Fix typo.
6021
60222011-08-02 Vincent Celier <celier@adacore.com>
6023
6024 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
6025 archive file name. Do not use the full path name of archives for Open
6026 VMS.
6027
eaba57fb
RD
60282011-08-02 Robert Dewar <dewar@adacore.com>
6029
6030 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
6031 Analyze_Aspect_Specifications
6032 * sem_ch13.adb
6033 (Analyze_Aspect_Specifications): New handling for boolean aspects
6034 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
6035 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
6036 sequence for Analyze_Aspect_Specifications
6037 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
6038 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
6039
60402011-08-02 Robert Dewar <dewar@adacore.com>
6041
6042 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
6043 aspects, since these no longer exist.
6044
60452011-08-02 Robert Dewar <dewar@adacore.com>
6046
6047 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
6048 semicolon, do not try to see if there are aspects following it.
6049 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
6050 aspect spec.
6051
8830d1d2
AC
60522011-08-02 Robert Dewar <dewar@adacore.com>
6053
6054 * sem_ch8.adb, aspects.ads: Minor reformatting.
6055
60562011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6057
6058 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
6059 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
6060 extracted from...
6061 (Analyze_Aspect_Specifications): ...here. Call above procedure.
6062
7ff2d234
AC
60632011-08-02 Yannick Moy <moy@adacore.com>
6064
6065 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
6066 mode on subprogram declaration outside of package specification, unless
6067 it is followed by a pragma Import
6068 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
6069 Access_Type_Declaration): issue error in formal mode on access type
6070 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
6071 incomplete type
6072 (Analyze_Object_Declaration): issue error in formal mode on object
6073 declaration which does not respect SPARK restrictions
6074 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
6075 declaration which does not respect SPARK restrictions
6076 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
6077 error in formal mode on digits or delta constraint
6078 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
6079 decimal fixed point type
6080 (Derived_Type_Declaration): issue error in formal mode on derived type
6081 other than type extensions of tagged record types
6082 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
6083 with check on access definition
6084 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
6085 mode on protected definition.
6086 (Analyze_Task_Definition): issue error in formal mode on task definition
6087
60882011-08-02 Robert Dewar <dewar@adacore.com>
6089
6090 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
6091
806f6d37
AC
60922011-08-02 Javier Miranda <miranda@adacore.com>
6093
6094 * sem_ch6.adb (Can_Override_Operator): New function.
6095 (Verify_Overriding_Indicator): Add missing code to check overriding
6096 indicator in operators. Fixes regression.
6097 (Check_Overriding_Indicator): Minor reformating after replacing the
6098 code that evaluates if the subprogram can override an operator by
6099 invocations to the above new function.
6100 * einfo.adb
6101 (Write_Field26_Name): Add missing code to ensure that, following
6102 the documentation in einfo.ads, this field is not shown as attribute
6103 "Static_Initialization" on non-dispatching functions.
6104
61052011-08-02 Jose Ruiz <ruiz@adacore.com>
6106
6107 * sem_res.adb (Resolve_Call): A call to
6108 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
6109 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
6110 i.e., when the second parameter is of type Time_Span.
6111
61122011-08-02 Vincent Celier <celier@adacore.com>
6113
6114 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
6115 with an archive instead of -L<library dir> -l<library name>.
6116
61172011-08-02 Ed Schonberg <schonberg@adacore.com>
6118
6119 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
6120 mark the base types In_Use in addition to making the operations
6121 use_visible.
6122
61232011-08-02 Ed Falis <falis@adacore.com>
6124
6125 * init.c: add and setup __gnat_signal_mask for the exception signals
6126 * s-inmaop-vxworks.adb: new file.
6127 * s-intman-vxworks.adb: remove unnecessary initializations and
6128 simplify remaining
6129 * s-intman-vxworks.ads: remove unnecessary variable
6130 * s-taprop-vxworks.adb: simplify signal initialization
6131
780d052e
RD
61322011-08-02 Robert Dewar <dewar@adacore.com>
6133
6134 * sem_ch8.adb: Minor code reorganization, comment updates.
6135
61362011-08-02 Robert Dewar <dewar@adacore.com>
6137
6138 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
6139 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
6140 here from Sem_Res.
6141 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
6142 (Matching_Static_Array_Bounds): Moved here from Sem_Res
6143
29efbb8c
ES
61442011-08-02 Ed Schonberg <schonberg@adacore.com>
6145
6146 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
6147 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
6148 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
6149 use_type_clauses, to handle more efficiently use_type and use_all_type
6150 constructs.
6151 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
6152 Ada2012 Use_All_Type clause.
6153 (Use_Class_Wide_Operations): new procedure.
6154
b0186f71
AC
61552011-08-02 Robert Dewar <dewar@adacore.com>
6156
6157 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
6158 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
6159 expression to expression function.
6160
61612011-08-02 Ed Schonberg <schonberg@adacore.com>
6162
6163 * sem_ch4.adb: transform simple Ada2012 membership into equality only
6164 if types are compatible.
6165
61662011-08-02 Yannick Moy <moy@adacore.com>
6167
6168 * sem_res.adb (Matching_Static_Array_Bounds): new function which
6169 returns True if its argument array types have same dimension and same
6170 static bounds at each index.
6171 (Resolve_Actuals): issue an error in formal mode on actuals passed as
6172 OUT or IN OUT paramaters which are not view conversions in SPARK.
6173 (Resolve_Arithmetic_Op): issue an error in formal mode on
6174 multiplication or division with operands of fixed point types which are
6175 not qualified or explicitly converted.
6176 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
6177 Boolean or array type (except String) operands.
6178 (Resolve_Equality_Op): issue an error in formal mode on equality
6179 operators for array types other than String with non-matching static
6180 bounds.
6181 (Resolve_Logical_Op): issue an error in formal mode on logical operators
6182 for array types with non-matching static bounds. Factorize the code in
6183 Matching_Static_Array_Bounds.
6184 (Resolve_Qualified_Expression): issue an error in formal mode on
6185 qualified expressions for array types with non-matching static bounds.
6186 (Resolve_Type_Conversion): issue an error in formal mode on type
6187 conversion for array types with non-matching static bounds
6188
767bb4e8
AC
61892011-08-02 Robert Dewar <dewar@adacore.com>
6190
6191 * par-ch10.adb: Minor code reorganization (use Nkind_In).
6192
61932011-08-02 Ed Schonberg <schonberg@adacore.com>
6194
6195 * par-ch9.adb: save location of entry for proper error message.
6196
4ac2477e
JM
61972011-08-02 Javier Miranda <miranda@adacore.com>
6198
6199 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
6200 (Use_Full_View) which permits this routine to climb through the
6201 ancestors using the full-view of private parents.
6202 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
6203 Use_Full_View to true in calls to Is_Ancestor.
6204 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
6205 true in call to Is_Ancestor.
6206 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
6207 Use_Full_View to true in call to Is_Ancestor.
6208 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
6209 call to Is_Ancestor.
6210 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
6211 Use_Full_View to true in calls to Is_Ancestor.
6212 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
6213 Make_Select_Specific_Data_Table, Register_Primitive,
6214 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
6215 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
6216 to true in call to Is_Ancestor.
6217 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
6218 Use_Full_View to true in calls to Is_Ancestor.
6219 * exp_cg.adb
6220 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
6221 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
6222
9f90d123
AC
62232011-08-02 Robert Dewar <dewar@adacore.com>
6224
6225 * gnat_rm.texi: Minor reformatting.
6226 * sem_prag.adb: Minor reformatting.
6227
62282011-08-02 Tristan Gingold <gingold@adacore.com>
6229
6230 * vms_data.ads: Add VMS qualifier for -gnateP.
6231
62322011-08-02 Robert Dewar <dewar@adacore.com>
6233
6234 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
6235 * par-ch7.adb (P_Package): Proper placement of aspects for package
6236 decl/instantiation.
6237 * par-endh.adb (Check_End): Ad Is_Sloc parameter
6238 (End_Statements): Add Is_Sloc parameterr
6239 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
6240 (Check_End): Ad Is_Sloc parameter
6241 (End_Statements): Add Is_Sloc parameterr
6242
62432011-08-02 Vincent Celier <celier@adacore.com>
6244
6245 * ug_words: Add VMS qualifier equivalent to -gnateP:
6246 /SYMBOL_PREPROCESSING.
6247
62482011-08-02 Jose Ruiz <ruiz@adacore.com>
6249
6250 * gnat-style.texi: For hexadecimal numeric literals the typical
6251 grouping of digits is 4 to represent 2 bytes.
6252 A procedure spec which is split into several lines is indented two
6253 characters.
6254
62552011-08-02 Yannick Moy <moy@adacore.com>
6256
6257 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
6258 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
6259 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
6260 properly qualified
6261 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
6262 choice in array aggregate
6263 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
6264 mark as ancestor
6265 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
6266 positional and named aggregate for record, or others in record
6267 aggregate, or multiple choice in record aggregate
6268 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
6269 array operands to logical operations AND, OR and XOR do not have the
6270 same static lower and higher bounds
6271 * sem_ch5.adb, sinfo.ads: Correct typos in comments
6272
2933b16c
RD
62732011-08-01 Robert Dewar <dewar@adacore.com>
6274
6275 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
6276 Replaces Last_Source_Node_In_Sequence.
6277 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
6278 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
6279 parens and blank in string (this was inconsistently implemented).
6280 * errout.ads
6281 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
6282 blank in string (this was inconsistently implemented).
6283 * gnat1drv.adb
6284 (Set_Global_Switches): Set formal mode switches appropriately
6285 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
6286 * par-prag.adb
6287 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
6288 call Set_Error_Msg_Lang to set "spark" as language name.
6289 * par.adb: Remove unnecessary call to set formal language for errout
6290 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
6291 appropriately and call Set_Error_Msg_Lang to set "spark" as language
6292 name.
6293 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
6294 calls to it, moved after resolution so that types are known
6295 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
6296 result of concatenation is not of type String
6297 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
6298 concatenation is not properly restricted
6299 * gnat_rm.texi: Add doc on pragma Spark_95.
6300 * gcc-interface/Makefile.in: Remove obsolete target pairs for
6301 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
6302 * gcc-interface/Make-lang.in: Update dependencies.
6303
05dbd302
AC
63042011-08-01 Javier Miranda <miranda@adacore.com>
6305
6306 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
6307 condition that detects if the overridden operation must replace an
6308 existing entity.
6309
63102011-08-01 Javier Miranda <miranda@adacore.com>
6311
6312 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
6313 code declarations inserted by Insert_Actions in each alternative of the
6314 N_Case_Expression node.
6315
63162011-08-01 Robert Dewar <dewar@adacore.com>
6317
6318 * sem_ch6.adb: Minor code reorganization.
6319 * sem_util.adb: Minor reformatting.
6320
af9e051f
PO
63212011-08-01 Pascal Obry <obry@adacore.com>
6322
6323 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
6324 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
6325
1d801f21
AC
63262011-08-01 Yannick Moy <moy@adacore.com>
6327
6328 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
6329 literal or operator symbol which is prefixed
6330 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
6331 mode on access attributes.
6332 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
6333 that concatenation operands are properly restricted in formal mode
6334 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
6335 Analyze_Concatenation_Operand. Issue an error in formal mode if the
6336 result of the concatenation has a type different from String.
6337 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
6338 Analyze_Quantified_Expression, Analyze_Slice,
6339 Analyze_Null): issue an error in formal mode on unsupported constructs
6340 * sem_ch5.adb
6341 (Analyze_Block_Statement): only issue error on source block statement
6342 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
6343 function which returns the last node in a list of nodes for which
6344 Comes_From_Source returns True, if any
6345 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
6346 Last_Source_Node_In_Sequence
6347 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
6348 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
6349 mode on unsupported constructs
6350 * sem_ch9.adb Do not return after issuing error in formal mode, as the
6351 rest of the actions may be needed later on since the error is marked as
6352 not serious.
6353 * sinfo.ads: Typos in comments.
6354
63552011-08-01 Pascal Obry <obry@adacore.com>
6356
6357 * projects.texi: Minor editing.
6358
53beff22
YM
63592011-08-01 Yannick Moy <moy@adacore.com>
6360
6361 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
6362 insertion character ~~
6363 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
6364 (Set_Error_Msg_Lang): new procedure which fixes the language for use
6365 with insertion character ~~
6366 (Set_Msg_Text): treat insertion character ~~
6367 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
6368 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
6369 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
6370 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
6371 errors related to the formal language restriction not serious
6372 (insertion character |).
6373 * par.adb (Par): set formal language for error messages if needed
6374 * sem_ch6.adb (Check_Missing_Return): take into account possible
6375 generated statements at the end of the function
6376 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
6377 enumeration value to define a new pragma SPARK_95
6378 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
6379 SPARK_Version): new type and variables to store the SPARK version
6380 (none by default).
6381 (SPARK_Mode): return True when SPARK_Version is set
6382 * par-prag.adb: Correct indentation
6383 (Prag): take Pragma_SPARK_95 into account
6384 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
6385 into account.
6386
8d606a78
RD
63872011-08-01 Robert Dewar <dewar@adacore.com>
6388
6389 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
6390 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
6391 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
6392
1982d5a8
PO
63932011-08-01 Pascal Obry <obry@adacore.com>
6394
6395 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
6396 Target_Name to Get_Path call.
6397 (Parse_Single_Project): Likewise.
6398 (Post_Parse_Context_Clause): Likewise.
6399 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
6400 Call Initialise_Project_Path with the proper Target_Name.
6401 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
6402 search path.
6403 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
6404 with the proper Target_Name.
6405 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
6406 Part.Parse routine.
6407 (Parse_Project_And_Apply_Config): Likewise.
6408 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
6409 This is fine as this part of the code is supporting only native
6410 compilation.
6411 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
6412 is fine as this part of the code is supporting only native compilation.
6413
0d53d36b
AC
64142011-08-01 Yannick Moy <moy@adacore.com>
6415
6416 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
6417 of homonym, unless the homonym is one of the cases allowed in SPARK
6418 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
6419 package declaration occurring after a body.
6420
64212011-08-01 Robert Dewar <dewar@adacore.com>
6422
6423 * checks.adb, exp_ch4.adb: Minor reformatting.
6424
64252011-08-01 Javier Miranda <miranda@adacore.com>
6426
6427 * einfo.ads (Access_Disp_Table): Fix documentation.
6428 (Dispatch_Table_Wrappers): Fix documentation.
6429
64302011-08-01 Pascal Obry <obry@adacore.com>
6431
6432 * prj-env.adb, prj-env.ads: Minor reformatting.
6433
8ed68165
AC
64342011-08-01 Yannick Moy <moy@adacore.com>
6435
6436 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
6437 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
6438 procedures out of these packages.
6439 * errout.ads, errout.adb
6440 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
6441 procedures in of this package
6442 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
6443 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
6444 on misplaced later vs initial declarations, like in Ada 83
6445 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
6446 formal mode on attribute of private type whose full type declaration
6447 is not visible
6448 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
6449 package declaration inside a package specification
6450 (Analyze_Full_Type_Declaration): issue error in formal mode on
6451 controlled type or discriminant type
6452 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
6453 user-defined operator means that it should come from the source
6454 (New_Overloaded_Entity): issue error in formal mode on overloaded
6455 entity.
6456 * sem_ch6.ads, sem_ch13.ads: typos in comments.
6457
64582011-08-01 Thomas Quinot <quinot@adacore.com>
6459
6460 * atree.adb: Minor reformatting.
6461 * checks.adb: Minor reformatting.
6462
4230bdb7
AC
64632011-08-01 Vincent Celier <celier@adacore.com>
6464
6465 * s-parame-vms-ia64.ads: Fix typo in comment
6466 Minor reformatting
6467 * s-parame-vms-restrict.ads: Removed, unused.
6468
64692011-08-01 Javier Miranda <miranda@adacore.com>
6470
6471 * exp_ch3.adb
6472 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
6473 * sem_ch3.adb
6474 (Constrain_Index): Remove side effects in the evaluation of the bounds.
6475 * sem_ch3.ads, sem_ch3.adb
6476 (Is_Constant_Bound): New extended version of the subprogram that was
6477 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
6478 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
6479 * sem_aux.ads (Constant_Value): Fix typo in comment.
6480 * checks.adb (Generate_Index_Checks): New implementation which, for
6481 array objects with constant bounds, generates the runtime check
6482 referencing the bounds of the array type. For other cases this routine
6483 provides its previous behavior obtaining such values from the array
6484 object.
6485 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
6486 parent type.
6487 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
6488 we cannot have semantic interpretations of the new node.
6489
2010d078
AC
64902011-08-01 Ed Schonberg <schonberg@adacore.com>
6491
6492 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
6493 expressions.
6494
64952011-08-01 Arnaud Charlet <charlet@adacore.com>
6496
6497 * sem_ch8.adb: Minor code editing.
6498 * s-vxwext.adb: Remove trailing space.
6499 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
6500 consistency with other files.
6501
65022011-08-01 Thomas Quinot <quinot@adacore.com>
6503
6504 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
6505
65062011-08-01 Ed Schonberg <schonberg@adacore.com>
6507
6508 * par-ch10.adb: reject parameterized expressions as compilation unit.
6509 * sem_ch4.adb: handle properly conditional expression with overloaded
6510 then_clause and no else_clause.
6511
65122011-08-01 Tristan Gingold <gingold@adacore.com>
6513
6514 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
6515 like done by System.Aux_DEC.
6516 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
6517
daec8eeb
YM
65182011-08-01 Yannick Moy <moy@adacore.com>
6519
6520 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
6521 missing label at end of declaration (subprogram or package)
6522 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
6523 of positional and named parameter association
6524 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
6525 Error_Msg_SP which adds a prefix to the error message giving the name
6526 of the formal language analyzed
6527 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
6528 access result type in subprogram, unconstrained array as result type,.
6529 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
6530 procedure
6531 * sem_ch8.adb: Code clean up.
6532
38171f43
AC
65332011-08-01 Javier Miranda <miranda@adacore.com>
6534
6535 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
6536 * einfo.ads (Access_Disp_Table): Fix documentation.
6537 (Dispatch_Table_Wrappers): Fix documentation.
6538 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
6539 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
6540 to enforce the documentation of this attribute.
6541 (Set_Is_Interface): Cleanup the assertion.
6542 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
6543 the Underlying_Type entity before reading attribute Access_Disp_Table.
6544 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
6545 Locate the Underlying_Type before reading attribute Access_Disp_Table.
6546 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
6547 the Underlying_Type entity before reading attribute Access_Disp_Table.
6548 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
6549 Locate the Underlying_Type entity before reading attribute
6550 Access_Disp_Table.
6551
65522011-08-01 Ed Schonberg <schonberg@adacore.com>
6553
6554 * s-poosiz.ads: Additional overriding indicators.
6555
65562011-08-01 Yannick Moy <moy@adacore.com>
6557
6558 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
6559 formal mode.
6560 (Analyze_Iteration_Scheme): issue error in formal mode when loop
6561 parameter specification does not include a subtype mark.
6562 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
6563 formal mode on abstract subprogram.
6564 (Analyze_Subprogram_Specification): issue error in formal mode on
6565 user-defined operator.
6566 (Process_Formals): issue error in formal mode on access parameter and
6567 default expression.
6568 * sem_ch9.adb (Analyze_Abort_Statement,
6569 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
6570 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
6571 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
6572 Analyze_Requeue, Analyze_Selective_Accept,
6573 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
6574 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
6575 issue error in formal mode on user-defined raise statement.
6576
1f250383
AC
65772011-08-01 Thomas Quinot <quinot@adacore.com>
6578
6579 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
6580 declaration being hidden when overriding an implicit inherited
6581 subprogram.
6582 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
6583 (-gnats), do not complain about a source file that contains only a
6584 pragma No_Body.
6585
65862011-08-01 Ed Schonberg <schonberg@adacore.com>
6587
6588 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
6589 variable if already set.
6590
607d0635
AC
65912011-08-01 Arnaud Charlet <charlet@adacore.com>
6592
6593 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
6594 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
6595 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
6596 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
6597 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
6598 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
6599 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
6600 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
6601 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
6602 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
6603 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
6604 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
6605 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
6606 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
6607 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
6608 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
6609 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
6610 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
6611 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
6612 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
6613 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
6614 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
6615 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
6616 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
6617 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
6618 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
6619 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
6620 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
6621 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
6622 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
6623 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
6624 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
6625 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
6626 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
6627 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
6628 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
6629 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
6630 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
6631 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
6632 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
6633 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
6634 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
6635 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
6636 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
6637 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
6638 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
6639 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
6640 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
6641 s-osinte-mingw.ads: Update to GPLv3 run-time license.
6642 Use GNAT instead of GNARL.
6643
66442011-08-01 Bob Duff <duff@adacore.com>
6645
6646 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
6647 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
6648 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
6649 reformatting.
6650
66512011-08-01 Yannick Moy <moy@adacore.com>
6652
6653 * debug.adb (d.D) reverve flag for the SPARK mode
6654 (d.E) reverve flag for SPARK generation mode
6655 (d.F) reverve flag for Why generation mode
6656 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
6657 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
6658 functions which return True when the corresponding modes are set
6659 (Formal_Language): return "spark" or "alfa" when in formal verification
6660 mode.
6661 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
6662 Error_Msg to prefix the error message with a tag giving the formal
6663 language
6664 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
6665 message with a tag giving the formal language
6666 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
6667 block statement
6668 (Analyze_Case_Statement): issue error in formal mode on case statement
6669 with a single "others" case alternative
6670 (Analyze_Exit_Statement): issue errors in formal mode on exit
6671 statements which do not respect SPARK restrictions
6672 (Analyze_Goto_Statement): issue error in formal mode on goto statement
6673 (Check_Unreachable_Code): always issue an error (not a warning) in
6674 formal mode on unreachable code (concerns both code after an infinite
6675 loop and after an unconditional jump, both not allowed in SPARK)
6676 * sem_ch6.adb (Analyze_Return_Statement): add call to
6677 Set_Return_Present for a procedure containing a return statement
6678 (already done for functions in Analyze_Function_Return)
6679 (Analyze_Function_Return): issue error in formal mode on extended
6680 return or if return is not last statement in function
6681 (Check_Missing_Return): issue error in formal mode if function does
6682 not end with return or if procedure contains a return
6683 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
6684 function to detect if there is an inner scope of its parameter S which
6685 is a loop.
6686
66872011-08-01 Thomas Quinot <quinot@adacore.com>
6688
6689 * sem_ch6.ads: Minor reformatting.
6690
d8b3ccb9
AC
66912011-08-01 Javier Miranda <miranda@adacore.com>
6692
6693 * sem_util.adb (Abstract_Interface_List): Complete condition when
6694 processing private type declarations to avoid reading unavailable
6695 attribute.
6696 (Is_Synchronized_Tagged_Type): Complete condition when processing
6697 private extension declaration nodes to avoid reading unavailable
6698 attribute.
6699
67002011-08-01 Thomas Quinot <quinot@adacore.com>
6701
6702 * sem_ch3.adb: Minor reformatting.
6703
67042011-08-01 Thomas Quinot <quinot@adacore.com>
6705
6706 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
6707 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
6708 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
6709 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
6710 for VMS, instead parametrize the common implementation with
6711 System.Parameters declarations.
6712
0bb9276c
AC
67132011-08-01 Eric Botcazou <ebotcazou@adacore.com>
6714
6715 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
6716
67172011-08-01 Tristan Gingold <gingold@adacore.com>
6718
6719 * seh_init.c: Fix SEH handler installation on win64.
6720
67212011-08-01 Ed Schonberg <schonberg@adacore.com>
6722
6723 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
6724 double analysis of an anonymous access to subprogram, because it can
6725 lead to improper sharing of profiles and a back-end crash.
6726
6a2e4f0b
AC
67272011-08-01 Robert Dewar <dewar@adacore.com>
6728
6729 * make.adb, sem_ch4.adb: Minor reformatting.
6730 * gcc-interface/Make-lang.in: Update dependencies.
6731 * sem_util.adb, exp_ch5.adb: Minor reformatting.
6732
67332011-08-01 Arnaud Charlet <charlet@adacore.com>
6734
6735 * gnat_rm.texi: Fix definition of Long_Integer.
6736
67372011-08-01 Ed Schonberg <schonberg@adacore.com>
6738
6739 * exp_aggr.adb: check limit size of static aggregate unconditionally,
6740 to prevent storage exhaustion.
6741 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
6742 finalized is a function body, insert the cleanup code before the final
6743 return statement, to prevent spurious warnings.
6744 * s-pooglo.ads: add overriding indicator.
6745
4561baf7
ES
67462011-08-01 Ed Schonberg <schonberg@adacore.com>
6747
6748 * sem_ch4.adb (Operator_Check): improve error message when both a
6749 with_clause and a use_clause are needed to make operator usage legal.
6750 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
6751 determine whether a compilation unit is visible within an other,
6752 either through a with_clause in the current unit, or a with_clause in
6753 its library unit or one one of its parents.
6754
383e179e
AC
67552011-08-01 Ed Schonberg <schonberg@adacore.com>
6756
6757 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
6758 over an arbitrary expression of an array or container type.
6759 * lib-xref.adb: clarify comment.
6760
67612011-08-01 Bob Duff <duff@adacore.com>
6762
6763 * einfo.ads: Minor reformatting.
6764 * debug.adb: Minor comment improvement.
6765
67662011-08-01 Javier Miranda <miranda@adacore.com>
6767
6768 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
6769 consider hidden subprograms as valid candidates.
6770
67712011-08-01 Arnaud Charlet <charlet@adacore.com>
6772
6773 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
6774
67752011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
6776
6777 * gnat_ugn.texi: Fix typo.
6778
61c161b2
AC
67792011-08-01 Robert Dewar <dewar@adacore.com>
6780
6781 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
6782 lib-xref.adb: Minor reformatting
6783
67842011-08-01 Gary Dismukes <dismukes@adacore.com>
6785
6786 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
6787 when to generate a call to Move_Final_List.
6788 (Has_Controlled_Parts): Remove this function.
6789
84df40f7
AC
67902011-08-01 Geert Bosch <bosch@adacore.com>
6791
6792 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
6793 "," in choice list.
6794
67952011-08-01 Thomas Quinot <quinot@adacore.com>
6796
6797 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
6798 explicit raise of a predefined exception as Comes_From_Source if the
6799 original N_Raise_Statement comes from source.
6800
68012011-08-01 Robert Dewar <dewar@adacore.com>
6802
6803 * sinfo.ads: Add comment.
6804 * sem_ch6.adb: Minor reformatting.
6805
68062011-08-01 Robert Dewar <dewar@adacore.com>
6807
6808 * freeze.adb (Freeze_Entity): Refine check for bad component size
6809 clause to avoid rejecting confirming clause when atomic/aliased present.
6810
68112011-08-01 Ed Schonberg <schonberg@adacore.com>
6812
6813 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
6814 better determine whether an entity reference is a write.
6815 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
6816 subcomponent.
6817 * lib-xref.adb (Output_References): Do no suppress a read reference at
6818 the same location as an immediately preceeding modify-reference, to
6819 handle properly in-out actuals.
6820
68212011-08-01 Tristan Gingold <gingold@adacore.com>
6822
6823 * env.c (__gnat_setenv) [VMS]: Refine previous change.
6824
68252011-08-01 Quentin Ochem <ochem@adacore.com>
6826
6827 * i-cstrin.adb (New_String): Changed implementation, now uses only the
6828 heap to compute the result.
6829
c7f0d2c0
AC
68302011-08-01 Robert Dewar <dewar@adacore.com>
6831
6832 * atree.ads: Minor reformatting.
6833
68342011-08-01 Emmanuel Briot <briot@adacore.com>
6835
6836 * g-expect.adb (Get_Command_Output): Fix memory leak.
6837
68382011-08-01 Geert Bosch <bosch@adacore.com>
6839
6840 * cstand.adb (P_Float_Type): New procedure to print the definition of
6841 predefined fpt types.
6842 (P_Mixed_Name): New procedure to print a name using mixed case
6843 (Print_Standard): Use P_Float_Type for printing floating point types
6844 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
6845 precision IEEE float.
6846
68472011-08-01 Thomas Quinot <quinot@adacore.com>
6848
6849 * sem_ch3.adb: Minor reformatting.
6850
68512011-08-01 Ed Schonberg <schonberg@adacore.com>
6852
6853 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
6854 the completion of a generic function, insert the new body rather than
6855 rewriting the original.
6856
68572011-08-01 Yannick Moy <moy@adacore.com>
6858
6859 * sinfo.ads, errout.ads: Typos in comments.
6860
1c54829e
AC
68612011-08-01 Robert Dewar <dewar@adacore.com>
6862
6863 * par-endh.adb: Minor reformatting.
6864
68652011-08-01 Robert Dewar <dewar@adacore.com>
6866
6867 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
6868 (Pre_Post_Aspects): New subtype.
6869 * par-ch12.adb (P_Generic): New syntax for aspects in packages
6870 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
6871 * par-ch7.adb (P_Package): Remove Decl parameter
6872 (P_Package): Handle new syntax for aspects (before IS)
6873 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
6874 new aspect syntax
6875 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
6876 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
6877 (P_Package): Remove Decl parameter
6878 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
6879 aspects
6880 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
6881 specs
6882 * sem_util.ads, sem_util.adb (Static_Boolean): New function
6883 * sinfo.ads: Document new syntax for aspects in packages etc.
6884 * sprint.adb: Handle new syntax of aspects before IS in package
6885
68862011-08-01 Thomas Quinot <quinot@adacore.com>
6887
6888 * atree.ads: Minor reformatting.
6889 * sem_prag.adb: Minor reformatting.
6890
68912011-08-01 Robert Dewar <dewar@adacore.com>
6892
6893 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
6894 case expr alternative.
6895
68962011-08-01 Ed Schonberg <schonberg@adacore.com>
6897
6898 * sem_ch12.adb: Fix typo.
6899
9eea4346
GB
69002011-08-01 Geert Bosch <bosch@adacore.com>
6901
6902 * sem_prag.adb (Check_No_Link_Name): New procedure.
6903 (Process_Import_Or_Interface): Use Check_No_Link_Name.
6904 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
6905 instead of Standard_Long_Long_Float_Size global. Preparation for
6906 eventual removal of per type constants.
6907 * exp_util.ads (Get_Stream_Size): New function returning the stream
6908 size value of subtype E.
6909 * exp_util.adb (Get_Stream_Size): Implement new function.
6910 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
6911 function.
6912 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
6913 * einfo.adb:
6914 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
6915
3d6c3bd7
GB
69162011-08-01 Geert Bosch <bosch@adacore.com>
6917
6918 * cstand.adb: Fix comments.
6919 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
6920 count of arguments.
6921
e7d897b8
AC
69222011-08-01 Robert Dewar <dewar@adacore.com>
6923
6924 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
6925
69262011-08-01 Geert Bosch <bosch@adacore.com>
6927
6928 * atree.ads: Fix comment.
6929
c228a069
AC
69302011-08-01 Robert Dewar <dewar@adacore.com>
6931
6932 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
6933 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
6934 * par.adb: Add with for Namet.Sp.
6935 * par-tchk.adb: Minor reformatting.
6936
69372011-08-01 Vincent Celier <celier@adacore.com>
6938
6939 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
6940 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
6941 of the init procedure of a SAL.
6942 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
6943 New procedure.
6944
69452011-08-01 Thomas Quinot <quinot@adacore.com>
6946
6947 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
6948 reformatting.
6949
69502011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
6951
6952 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
6953
69542011-08-01 Thomas Quinot <quinot@adacore.com>
6955
6956 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
6957 conformant with its spec (return True only for types that have
6958 an overriding Initialize primitive operation that prevents them from
6959 having preelaborable initialization).
6960 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
6961 initialization for controlled types in Ada 2005 or later mode.
6962
857ade1b
RD
69632011-08-01 Robert Dewar <dewar@adacore.com>
6964
6965 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
6966 Postcondition.
6967 (Same_Aspect): New function.
6968 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
6969 Type_Invariant, Precondition, Postcondition.
6970 * snames.ads-tmpl: Add Name_Type_Invariant.
6971
bd949ee2
RD
69722011-08-01 Robert Dewar <dewar@adacore.com>
6973
6974 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
6975 here.
6976 (Freeze_All_Ent): Fix error in handling inherited aspects.
6977 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
6978 already analyzed, but don't skip entire processing of a declaration,
6979 that's wrong in some cases of declarations being rewritten.
6980 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
6981 Don't delay for integer, string literals
6982 Treat predicates in usual manner for delay, remove special case code,
6983 not needed.
6984 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
6985 (Build_Predicate_Function): Update saved expression in aspect
6986 (Build_Invariant_Procedure): Update saved expression in aspect
6987 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
6988 of replacement of discriminant references if the reference is simple.
6989
f1c952af
RD
69902011-08-01 Robert Dewar <dewar@adacore.com>
6991
6992 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
6993 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
6994 Static_Predicate and Dynamic_Predicate.
6995 (Build_Predicate_Function): Add processing for Static_Predicate
6996 and Dynamic_Predicate.
6997 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
6998 (From_Static_Predicate): New flag
6999 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
7000
70012011-08-01 Robert Dewar <dewar@adacore.com>
7002
7003 * usage.adb: Documentation cleanup for Ada version modes in usage.
7004 * expander.adb: Minor reformatting.
7005
47e11d08
AC
70062011-08-01 Robert Dewar <dewar@adacore.com>
7007
7008 * atree.ads: Minor comment fix.
7009 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
7010 a-witeio.ads, sem_prag.adb: Minor reformatting.
7011
70122011-08-01 Doug Rupp <rupp@adacore.com>
7013
7014 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
7015 pointers. Use descrip.h header file for convenience. Add some
7016 comments.
7017
70182011-08-01 Robert Dewar <dewar@adacore.com>
7019
7020 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
7021 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
7022 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
7023 New procedure.
7024 (Check_Aspect_At_End_Of_Declarations): New procedure
7025 (Analye_Aspect_Specification): Minor changes for above procedures
7026 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
7027 specification node as well.
7028
70292011-08-01 Pascal Obry <obry@adacore.com>
7030
7031 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
7032 Windows files. Use GetFilesAttributes() in this case to check for file
7033 existence instead of returning with an error code.
7034
a3a16b21
VC
70352011-08-01 Vincent Celier <celier@adacore.com>
7036
7037 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
7038 High is above Source length.
7039
ff58cc69
RD
70402011-08-01 Robert Dewar <dewar@adacore.com>
7041
7042 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
7043
6bb88533
AC
70442011-08-01 Robert Dewar <dewar@adacore.com>
7045
7046 * aspects.ads (Boolean_Aspects): New subtype.
7047 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
7048 for derived types in cases where the parent type and derived type have
7049 aspects.
7050 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
7051 with aspects when parent type also has aspects.
7052 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
7053 boolean expression at this point).
7054 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
7055 accordance with final decision on the Ada 2012 feature.
7056 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
7057
70582011-08-01 Matthew Heaney <heaney@adacore.com>
7059
7060 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
7061
060a3f28
AC
70622011-08-01 Pascal Obry <obry@adacore.com>
7063
7064 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
7065 Fix Replace_Slice when High is above current string size.
7066 (Replace_Slice): Fix DL computation when High is above current
7067 string length.
7068
70692011-08-01 Gary Dismukes <dismukes@adacore.com>
7070
7071 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
7072
e7f567a3
AC
70732011-08-01 Matthew Heaney <heaney@adacore.com>
7074
7075 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
7076 of node.
7077
70782011-08-01 Pascal Obry <obry@adacore.com>
7079
7080 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
7081 reformatting.
7082
1a265e78
AC
70832011-08-01 Ed Schonberg <schonberg@adacore.com>
7084
7085 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
7086 access to protected subprograms in generic bodies.
7087 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
7088 protected type, indicate that the convention of the subprogram is
7089 Convention_Protected, because it may be used in subsequent declarations
7090 within the protected declaration.
7091
70922011-08-01 Vincent Celier <celier@adacore.com>
7093
7094 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
7095 and "final" procedures when the name of the library is "ada", to avoid
7096 duplicate symbols "adainit" and "adafinal" in executables.
7097
67e28ef8
ES
70982011-08-01 Ed Schonberg <schonberg@adacore.com>
7099
7100 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
7101 quantified expression that appears within a postcondition and uses the
7102 Ada2012 'Result attribute.
7103
6da2ca7d
RO
71042011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7105
7106 * init.c (__gnat_error_handler): Cast reason to int.
7107 (__gnat_install_handler): Explain sa_sigaction use.
7108
7d5997c6
EB
71092011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7110
7111 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
7112 subprogram has copy-in copy-out parameters, try to promote the mode of
7113 the return type if it is passed in registers.
7114
4b4cfdd5
EB
71152011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7116
7117 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
7118 left operand as addressable.
7119
f3d34576
EB
71202011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7121
7122 * gcc-interface/gigi.h (build_function_stub): Remove.
7123 (build_return_expr): Likewise.
7124 (convert_vms_descriptor): Declare.
7125 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
7126 (build_function_stub): Move to...
7127 * gcc-interface/utils2.c (build_return_expr): Move to...
7128 * gcc-interface/trans.c (build_function_stub): ...here.
7129 (build_return_expr): ...here.
7130 (Subprogram_Body_to_gnu): Add local variable for language_function.
7131 Disconnect the parameter attributes cache, if any, once done with it.
7132 Call end_subprog_body only after setting the end_locus.
7133 Build the stub associated with the function, if any, at the very end.
7134 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
7135 variables and streamline control flow.
7136
0a6ecc08
AC
71372011-07-23 Arnaud Charlet <charlet@adacore.com>
7138
7139 PR ada/49819
7140 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
7141 g-trasym-dwarf.adb.
7142
5b6d595b
RO
71432011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7144
7145 PR bootstrap/49794
7146 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
7147 Assign to act.sa_sigaction.
7148 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
7149 current->return_address to char * before arithmetic.
7150
94017021
RO
71512011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7152
7153 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
7154 Correct argument types.
7155 Extract code from reason.
7156 (__gnat_install_handler): Assign to act.sa_sigaction.
7157
52fd02bb
EB
71582011-07-21 Eric Botcazou <ebotcazou@adacore.com>
7159
7160 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
7161 (GNAT1_OBJS): ...here.
7162
f39a9ca2
EB
71632011-07-15 Eric Botcazou <ebotcazou@adacore.com>
7164
7165 PR ada/48711
7166 * g-socthi-mingw.adb (Fill): Fix formatting.
7167
9e36aa23
EB
7168 * gcc-interface/gigi.h: Move around comment.
7169
e3aca522
JDA
71702011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
7171
7172 PR ada/46350
7173 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
7174
696b1960
FW
71752011-07-14 Florian Weimer <fw@deneb.enyo.de>
7176
7177 PR ada/48711
7178 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
7179
f542c405
EB
71802011-07-13 Eric Botcazou <ebotcazou@adacore.com>
7181
7182 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
7183 range comparison if Pmode is SImode.
7184
9e9bd455
LG
71852011-07-12 Laurent GUERBY <laurent@guerby.net>
7186 Eric Botcazou <ebotcazou@adacore.com>
7187
7188 * adadecode.c: Wrap up in extern "C" block.
7189 * adadecode.h: Likewise.
7190 * adaint.c: Likewise. Remove 'const' keyword.
7191 * adaint.h: Likewise.
7192 * argv.c: Likewise.
7193 * atree.h: Likewise.
7194 * cio.c: Likewise.
7195 * cstreams.c: Likewise.
7196 * env.c: Likewise.
7197 * exit.c: Likewise.
7198 * fe.h: Likewise.
7199 * final.c: Likewise.
7200 * init.c: Likewise.
7201 * initialize.c: Likewise.
7202 * link.c: Likewise.
7203 * namet.h: Likewise.
7204 * nlists.h: Likewise.
7205 * raise.c: Likewise.
7206 * raise.h: Likewise.
7207 * repinfo.h: Likewise.
7208 * seh_init.c: Likewise.
7209 * targext.c: Likewise.
7210 * tracebak.c: Likewise.
7211 * uintp.h: Likewise.
7212 * urealp.h: Likewise.
7213 * xeinfo.adb: Wrap up generated C code in extern "C" block.
7214 * xsinfo.adb: Likewise.
7215 * xsnamest.adb: Likewise.
7216 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
7217 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
7218 * gcc-interface/misc.c: Likewise.
7219 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
7220 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
7221 ada/targext.o here...
7222 (GNAT_ADA_OBJS): ...and not here.
7223 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
7224 (GNATBIND_OBJS): Reorder.
7225
7644b3c7
RH
72262011-07-07 Richard Henderson <rth@redhat.com>
7227
7228 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
7229 dwarf2out_frame_init.
7230
8384ac41
EB
72312011-07-07 Eric Botcazou <ebotcazou@adacore.com>
7232
7233 * gcc-interface/misc.c (gnat_init): Tweak previous change.
7234
fbdd5d87
RO
72352011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7236
7237 PR target/39150
7238 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
7239
1a072294
RG
72402011-07-06 Richard Guenther <rguenther@suse.de>
7241
8384ac41
EB
7242 * gcc-interface/misc.c (gnat_init): Merge calls to
7243 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
7244 Re-initialize boolean_false_node.
7245
bc712852
EB
72462011-07-02 Eric Botcazou <ebotcazou@adacore.com>
7247 Olivier Hainque <hainque@adacore.com>
7248 Nicolas Setton <setton@adacore.com>
7249
7250 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
7251 the type according to the ARTIFICIAL_P parameter.
7252 (create_type_decl): Likewise.
7253 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
7254
2eb22389
EB
72552011-07-01 Eric Botcazou <ebotcazou@adacore.com>
7256
7257 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
7258 (gnatbind): Likewise.
7259
4bdaaf2f
RO
72602011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7261
7262 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
7263
c020c92b
EB
72642011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7265
7266 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
7267 local variable throughout. Remove useless call to Base_Type.
7268 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
7269 Take it also into account for the volatileness of the field. Set the
7270 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
7271
96769d32
EB
72722011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7273
7274 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
7275 on a dereference built for a by-ref object if it has an address clause.
7276
7e4680c1
EB
72772011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7278
7279 * einfo.ads (Address_Taken): Document use for the second argument of
7280 Asm_Input and Asm_Output attributes.
7281 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
7282 argument is an entity name, then set Address_Taken on it.
7283 <Attribute_Asm_Output>: Likewise.
7284 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
7285 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
7286 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
7287 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
7288
72892011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
7290
7291 PR middle-end/46500
7292 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
7293
677f3fa8
JM
72942011-06-14 Joseph Myers <joseph@codesourcery.com>
7295
7296 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
7297 (ada/utils.o): Update dependencies.
7298 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
7299 ../../../libcpp/libcpp.a.
7300 * gcc-interface/utils.c: Include common/common-target.h.
7301 (process_attributes): Use targetm_common.have_named_sections.
7302
009db074
RG
73032011-06-07 Richard Guenther <rguenther@suse.de>
7304
0bad0e23
EB
7305 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
7306 set_sizetype.
009db074 7307
3bfc61cf
EB
73082011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7309
0bad0e23 7310 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
7311 TREE_THIS_NOTRAP flag.
7312
5c4a1c7b
EB
73132011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7314
7315 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
7316 Fix thinko.
7317
e9f57686
EB
73182011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7319
7320 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
7321 constants whose full view has discriminants specially.
7322
10e4d056
EB
73232011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7324
7325 * gcc-interface/utils.c: Include diagnostic.h.
7326 (gnat_write_global_declarations): Output debug information for all
7327 global type declarations before finalizing the compilation unit.
7328 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
7329
0957c029
JJ
73302011-05-25 Jakub Jelinek <jakub@redhat.com>
7331
7332 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
7333
52d0a7ac
KT
73342011-05-25 Kai Tietz <ktietz@redhat.com>
7335
7336 * adaint.c (__gnat_to_canonical_file_list_next): Use array
7337 initialization instead of const/none-const pointer assignment.
7338
1ed1641d
JM
73392011-05-24 Joseph Myers <joseph@codesourcery.com>
7340
7341 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
7342 $(EXTRA_GNAT1_OBJS).
7343 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
7344 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
7345 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
7346 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
7347 libcommon-target.a instead of prefix.o.
7348
9fe72ebd
JM
73492011-05-21 Joseph Myers <joseph@codesourcery.com>
7350
7351 PR ada/49097
0bad0e23 7352 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 7353
2691e6d7
JM
73542011-05-20 Joseph Myers <joseph@codesourcery.com>
7355
0bad0e23
EB
7356 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
7357 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
7358 instead of version.o.
2691e6d7 7359
bf6490b5
KT
73602011-05-18 Kai Tietz <ktietz@redhat.com>
7361
7362 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
7363 boolean_false_node instead of integer_zero_node.
7364 (convert_with_check): Likewise.
7365 * gcc-interface/decl.c (choices_to_gnu): Likewise.
7366
7bf9a5ac
EB
73672011-05-12 Eric Botcazou <ebotcazou@adacore.com>
7368
7369 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
7370 type of the parameter is an unconstrained array, convert the actual to
7371 the type of the formal in the In Out and Out cases as well.
7372
e5b00edf
NF
73732011-05-11 Nathan Froyd <froydnj@codesourcery.com>
7374
7375 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
7376 call build_function_type_array or build_varargs_function_type_array
7377 instead.
7378 (create_subprog_type): Don't call build_function_type; call
7379 build_function_type_vec instead.
7380
51545682
NF
73812011-05-11 Nathan Froyd <froydnj@codesourcery.com>
7382
7383 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
7384 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
7385 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
7386
c99c0026
EB
73872011-05-07 Eric Botcazou <ebotcazou@adacore.com>
7388
f620bd21
EB
7389 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
7390
c99c0026
EB
7391 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
7392 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
7393
3d528853
NF
73942011-05-05 Nathan Froyd <froydnj@codesourcery.com>
7395
c99c0026 7396 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 7397
d7d058c5
NF
73982011-05-05 Nathan Froyd <froydnj@codesourcery.com>
7399
7400 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
7401 instead of accessing TYPE_ARG_TYPES directly.
7402 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
7403
805e60a0
EB
74042011-05-05 Eric Botcazou <ebotcazou@adacore.com>
7405
7406 PR ada/48844
7407 * gcc-interface/gigi.h (get_variant_part): Declare.
7408 * gcc-interface/decl.c (get_variant_part): Make global.
7409 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
7410 types have the same constant size, are record types and T1 has a
7411 variant part while T2 doesn't.
7412
907a08d9
EB
74132011-05-05 Eric Botcazou <ebotcazou@adacore.com>
7414
7415 * gcc-interface/utils.c (begin_subprog_body): Do not call
7416 get_pending_sizes.
7417 (end_subprog_body): Likewise.
7418
d35936ab
RG
74192011-05-04 Richard Guenther <rguenther@suse.de>
7420
7421 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
7422 int_const_binop.
7423 (pos_to_constructor): Likewise.
7424
c1fd8753
NF
74252011-05-03 Nathan Froyd <froydnj@codesourcery.com>
7426 Eric Botcazou <ebotcazou@adacore.com>
7427
7428 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
7429 of build_function_type. Adjust calls to...
7430 (build_raise_check): ...this. Do not take a void_tree parameter.
7431 Call build_function_type_list instead of build_function_type.
7432 Fix head comment and swap couple of conditional blocks.
7433
4fb87d2b
EB
74342011-04-30 Eric Botcazou <ebotcazou@adacore.com>
7435
7436 * gnatvsn.ads (Library_Version): Bump to 4.7.
7437 (Current_Year): Bump to 2011.
7438
fa5e5a76
MM
74392011-04-29 Michael Matz <matz@suse.de>
7440
7441 * gcc-interface/misc.c (gnat_handle_option): Set
7442 warn_maybe_uninitialized.
7443
8d6a2f69
GP
74442011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
7445
7446 * gnat_ugn.texi (Complexity Metrics Control): Update link to
7447 the Watson/McCabe paper.
7448
770937fd
JM
74492011-04-23 Jim Meyering <meyering@redhat.com>
7450
7451 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
7452
eb601ae1
EB
74532011-04-22 Eric Botcazou <ebotcazou@adacore.com>
7454
7455 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
7456 onto the new type.
7457
7d7fcb08
EB
74582011-04-22 Eric Botcazou <ebotcazou@adacore.com>
7459
7460 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
7461 parameter.
7462 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
7463 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
7464 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
7465 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
7466 <all>: Do not set flags on the reused DECL node coming from an alias.
7467 Set DECL_IGNORED_P on the DECL node built for subprograms if they
7468 don't need debug info here...
7469 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
7470 (gigi): Adjust calls to create_subprog_decl.
7471 (build_raise_check): Likewise.
7472 (establish_gnat_vms_condition_handler): Likewise.
7473 (Compilation_Unit_to_gnu): Likewise.
7474 (gnat_to_gnu): Likewise.
7475
e1876cac
EB
74762011-04-21 Eric Botcazou <ebotcazou@adacore.com>
7477
7478 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
7479 (NO_REORDER_ADAFLAGS): New variable.
7480 (EXTRA_GNATTOOLS): Always define.
7481 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
7482 Clean up and adjust list of files compiled with special options.
7483 * gcc-interface/Make-lang.in: Likewise.
7484 (ada/decl.o): Cosmetical change.
7485 (ada/misc.o): Remove dependency on $(PLUGIN_H).
7486
04695783
JM
74872011-04-20 Jim Meyering <meyering@redhat.com>
7488
7489 * initialize.c (__gnat_initialize): Remove useless if-before-free.
7490
23399579
EB
74912011-04-17 Eric Botcazou <ebotcazou@adacore.com>
7492
7493 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
7494 $(CFLAGS) on the link line.
7495
51c5169c
EB
74962011-04-17 Eric Botcazou <ebotcazou@adacore.com>
7497
7498 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
7499 padded type built for the return type if it is unconstrained.
7500
61e46a7d
NF
75012011-04-14 Nathan Froyd <froydnj@codesourcery.com>
7502
7503 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
7504
81f653d6
NF
75052011-04-12 Nathan Froyd <froydnj@codesourcery.com>
7506
b4867846
EB
7507 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
7508 before calling TREE_CHAIN.
81f653d6
NF
7509 * gcc-interface/misc.c (gnat_init_ts): New function.
7510 (LANG_HOOKS_INIT_TS): Define.
7511
a358e188
MJ
75122011-04-12 Martin Jambor <mjambor@suse.cz>
7513
b4867846
EB
7514 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
7515 instead of cgraph_node.
a358e188 7516
29b1c5a4
EB
75172011-04-08 Eric Botcazou <ebotcazou@adacore.com>
7518
7519 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
7520 alignment on fields of the RETURN type built for the Copy-In Copy-Out
7521 mechanism.
7522
88872b00
EB
75232011-04-08 Eric Botcazou <ebotcazou@adacore.com>
7524
7525 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
7526 of aggregate types that contain a placeholder.
7527
dcf0c47e
NF
75282011-04-08 Nathan Froyd <froydnj@codesourcery.com>
7529
7530 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 7531 TYPE_ARG_TYPES.
dcf0c47e
NF
7532 (handle_type_generic_attribute): Likewise.
7533
53e3000c
EB
75342011-04-04 Eric Botcazou <ebotcazou@adacore.com>
7535
7536 PR ada/47163
7537 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
7538
ab380bb4
KT
75392011-04-04 Kai Tietz <ktietz@redhat.com>
7540
7541 PR ada/47163
0bad0e23
EB
7542 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
7543 to flag value.
ab380bb4 7544
8ffac116
EB
75452011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7546
7547 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
7548 type case, do not strip a padding type around the array type.
7549
de9528f0
EB
75502011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7551
7552 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
7553 types.
7554
d9d7a26c
EB
75552011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7556
7557 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
7558 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 7559 code for -feliminate-unused-debug-types.
d9d7a26c
EB
7560 (gnat_post_options): Likewise.
7561
4cb12a90
EB
75622011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7563
7564 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
7565 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
7566 distinct copy.
7567
acccc61c
EB
75682011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7569
7570 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
7571 DECL_ARTIFICIAL flag on enumeration types.
7572
583eb0c9
EB
75732011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7574
7575 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
7576 fat pointer types artificial unconditionally.
7577 <E_Array_Subtype>: Attach the base array type as a parallel type if it
7578 isn't artificial.
7579
e3edbd56
EB
75802011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7581
7582 * gcc-interface/gigi.h (get_dummy_type): Declare.
7583 (build_dummy_unc_pointer_types): Likewise.
7584 (finish_fat_pointer_type): Likewise.
7585 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
7586 fat pointer type has been built, complete it in place.
7587 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
7588 and thin pointers. Remove useless variable.
7589 (finish_fat_pointer_type): Make global and move to...
7590 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
7591 (get_dummy_type): New function.
7592 (build_dummy_unc_pointer_types): Likewise.
7593 (gnat_pushdecl): Propage the name to the anonymous variants only.
7594 (update_pointer_to): Only adjust the pointer types in the unconstrained
7595 array case.
7596
65444786
EB
75972011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7598
7599 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
7600 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
7601 if this is a Taft amendment type and the full declaration is available.
7602 * gcc-interface/trans.c (process_type): Likewise.
7603 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
7604 (process_freeze_entity): Likewise.
7605 * gcc-interface/utils.c (dummy_global): New static variable.
7606 (gnat_write_global_declarations): If there are types declared as used
7607 at the global level, insert them in the global hash table.
7608
1aeb40dd
EB
76092011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7610
7611 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
7612 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
7613 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
7614 copy.
7615 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
7616 flag of the type accordingly.
7617 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
7618
80ec8b4c
EB
76192011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7620
7621 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
7622 finalizing types when updating the pointers to the designated type.
7623 <all>: Finalize the deferred types even if we didn't defer processing
7624 of incomplete types in this invocation.
7625
2a9d769a
OH
76262011-04-01 Olivier Hainque <hainque@adacore.com>
7627 Nicolas Setton <setton@adacore.com>
7628 Eric Botcazou <ebotcazou@adacore.com>
7629
7630 * gcc-interface/misc.c (gnat_descriptive_type): New function.
7631 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
7632
2438d7a6
KT
76332011-03-28 Kai Tietz <ktietz@redhat.com>
7634
333d8aff 7635 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
7636 Windows targets.
7637 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
7638 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 7639
80ec8b4c 7640 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 7641
8ad150f6
TG
76422011-03-28 Tristan Gingold <gingold@adacore.com>
7643
7644 PR ada/44431
80ec8b4c
EB
7645 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
7646 Use ada output of gnatbind.
8ad150f6
TG
7647 (ada/b_gnatb.adb): Ditto.
7648 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
7649 (ada.mostlyclean, ada.stage1)
7650 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
7651 (ada.stagefeedback): Adjust.
80ec8b4c 7652 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
7653 Use ada output of gnatbind.
7654 (b_gnatm.adb): Ditto.
7655 (b_gnatl.o, b_gnatm.o): New rules.
7656
51c7954d
EB
76572011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7658
7659 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
7660 for the padded type built to support a specified size or alignment.
7661
6ddf9843
EB
76622011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7663
7664 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
7665 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
7666 unconditionally to the end of the unit when the designated type is
7667 limited_with'ed.
7668 <all>: Rename local variable. Attempt to un-defer types only and do it
7669 for limited_with'ed types as well.
7670 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
7671 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
7672 consistently and remove redundant call to finalize_from_with_types.
7673
5daed84a
EB
76742011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7675
7676 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
7677 subprograms without a previous spec declared in the same unit.
7678 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
7679 subprograms at the end of the unit instead of at the beginning.
7680 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
7681 isn't public for the special handling of non-inline functions nested
7682 inside inline external functions.
7683
0edf1bb2
JL
76842011-03-25 Jeff Law <law@redhat.com>
7685
5daed84a 7686 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 7687
e3c4580e
EB
76882011-03-24 Eric Botcazou <ebotcazou@adacore.com>
7689
7690 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
7691 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
7692 to compute Set_Size_Depends_On_Discriminant.
7693 (Layout_Type): Call it on array types in back-end layout mode.
7694 * sem_util.adb (Requires_Transient_Scope): Return true for array
7695 types only if the size depends on the value of discriminants.
7696 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
7697 type if the RHS is a call to a function that returns an unconstrained
7698 type with default discriminant.
7699
abbc8c7b
EB
77002011-03-24 Eric Botcazou <ebotcazou@adacore.com>
7701
7702 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
7703 non-conversion to the nominal result type at the end.
7704
ddb5a105
EB
77052011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7706
7707 * gcc-interface/trans.c (create_temporary): New function taken from...
7708 (create_init_temporary): ...here. Call it.
7709 (call_to_gnu): Create the temporary for the return value early, if any.
7710 Create it for a function with copy-in/copy-out parameters if there is
7711 no target; in other cases of copy-in/copy-out, use another temporary.
7712 Push the new binding level lazily. Add and rename local variables.
7713
0d853156
EB
77142011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7715
7716 * gcc-interface/decl.c (validate_size): Improve comments and tweak
7717 error message.
7718 (set_rm_size): Likewise.
7719
4184ef1b
EB
77202011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7721
7722 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
7723 for the padded type built in order to support a specified alignment.
7724 Fix incorrect formatting.
7725
bf7eefab
EB
77262011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7727
7728 PR bootstrap/48216
7729 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
7730
ef0feeb2
EB
77312011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7732
7733 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
7734 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
7735 to the end of the list. Adjust recursive call. Rename local variable.
7736 If REORDER is true, reorder components of the record type.
7737 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
7738 components_to_record and adjust the parameter list.
7739
646f9414
EB
77402011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7741
7742 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
7743 disabled, use the variable for bounds of loop iteration scheme.
7744
62d784f7
KT
77452011-03-21 Kai Tietz <ktietz@redhat.com>
7746
7747 PR target/12171
0bad0e23 7748 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 7749
f230d759
EB
77502011-03-17 Eric Botcazou <ebotcazou@adacore.com>
7751
7752 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
7753 out whether the expression is read-only. Short-circuit placeholder
7754 case and rename a couple of local variables.
7755
bb1f7929
EB
77562011-03-17 Eric Botcazou <ebotcazou@adacore.com>
7757
7758 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
7759 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
7760 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
7761 (convert): Deal with conversions from a smaller form type specially.
7762
400a2d24
EB
77632011-02-14 Eric Botcazou <ebotcazou@adacore.com>
7764
7765 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
7766 its argument, except for the special -I- switch.
7767
c26bc3ad
GP
77682011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
7769
0bad0e23
EB
7770 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
7771 "Ada Issues".
c26bc3ad 7772
07b8e910
EB
77732011-02-08 Eric Botcazou <ebotcazou@adacore.com>
7774
7775 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
7776
31a5a547
EB
77772011-02-03 Eric Botcazou <ebotcazou@adacore.com>
7778
7779 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
7780 GNAT_FORMAL.
7781 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
7782 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
7783 instead of GNAT_FORMAL. Protect the expression against multiple uses.
7784 Do not generate the check directly, instead instantiate the template
7785 check present in the descriptor.
7786 (make_descriptor_field): Move around.
7787 (build_vms_descriptor32): Build a template check in the POINTER field.
7788 (build_vms_descriptor): Remove useless suffixes.
7789 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
7790
dcf25f59
EB
77912011-01-26 Eric Botcazou <ebotcazou@adacore.com>
7792
7793 PR bootstrap/47467
7794 * targext.c: Include target files if IN_RTS is defined.
7795
0418e131
RG
77962011-01-26 Richard Guenther <rguenther@suse.de>
7797
7798 PR bootstrap/47467
7799 * targext.c: Include config.h.
7800 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
7801 dependency.
7802
c6eecbd8
PO
78032011-01-04 Pascal Obry <obry@adacore.com>
7804 Eric Botcazou <ebotcazou@adacore.com>
7805
7806 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
7807
2d3c7e4f
EB
78082011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7809
7810 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
7811 end-of-case on the end label and its associated gotos, if any.
7812
0394741f
EB
78132011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7814
7815 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
7816 expressions of the parameter cache within the statement group of
7817 the CICO mechanism.
7818
2a02d090
OH
78192011-01-04 Olivier Hainque <hainque@adacore.com>
7820 Eric Botcazou <ebotcazou@adacore.com>
7821
7822 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
7823 (set_end_locus_from_node): New function.
7824 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
7825 make and the function end_locus.
7826 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
7827 for the elaboration subprogram.
7828 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
7829 set the end_locus of the expression as well.
7830
89f5e978
EB
78312011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7832
7833 PR ada/47131
7834 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
7835 variables that are referenced in exception handlers volatile.
7836
7837
ad41bd84 7838\f
797103eb 7839Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
7840
7841Copying and distribution of this file, with or without modification,
7842are permitted in any medium without royalty provided the copyright
7843notice and this notice are preserved.