1 2006-01-20 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
4 * s-osinte-linux-hppa.ads: Reduce alignment of atomic_lock_t to 8.
6 2005-12-28 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
8 * s-osinte-linux-hppa.ads: Correct alignment of atomic_lock_t.
10 2005-12-12 Arnaud Charlet <charlet@adacore.com>
12 * Makefile.in: Remove dummy setting of GCC_FOR_TARGET, no longer
15 2005-12-12 Arnaud Charlet <charlet@adacore.com>
17 * Make-lang.in: Update dependencies
19 2005-12-12 Arnaud Charlet <charlet@adacore.com>
21 * Make-lang.in: Add rule for ada/exp_sel.o
23 2005-12-12 Arnaud Charlet <charlet@adacore.com>
25 * Makefile.in (mingw section): Remove EH_MECHANISM setting.
27 2005-12-09 Arnaud Charlet <charlet@adacore.com>
29 * gnatvsn.ads (Library_Version): Bump to version 4.2
30 (ASIS_Version_Number): Bumped.
32 2005-12-09 Doug Rupp <rupp@adacore.com>
34 * mlib-tgt-vms-ia64.adb, mlib-tgt-vms-alpha.adb (Is_Interface): Change
35 Ada bind file prefix on VMS from b$ to b__.
36 (Build_Dynamic_Library): Change Init file suffix on VMS from $init to
39 * prj-nmsc.adb: Change some Hostparm.OpenVMS checks to
40 Targparm.OpenVMS_On_Target.
41 (Object_Suffix): Initialize with target object suffix.
42 (Get_Unit): Change Ada bind file prefix on VMS from b$ to b__.
44 * butil.adb: Change some Hostparm.OpenVMS checks to
45 Targparm.OpenVMS_On_Target.
47 * clean.adb: Change some Hostparm.OpenVMS checks to
48 Targparm.OpenVMS_On_Target.
49 (Object_Suffix): Initialize with call to Get_Target_Object_Suffix.
50 ({declaraction},Delete_Binder_Generated_Files,{initialization}): Change
51 Ada bind file prefix on VMS from b$ to b__.
53 * gnatlink.adb (Process_Args): Call Add_Src_Search_Dir for -I in
54 --GCC so that Get_Target_Parameters can find system.ads.
55 (Gnatlink): Call Get_Target_Parameters in mainline.
56 Initialize standard packages for Targparm.
57 Change some Hostparm.OpenVMS checks to Targparm.OpenVMS_On_Target.
58 (Process_Args): Also Check for object files with target object
60 (Make_Binder_File_Names): Create with target object extension.
61 (Make_Binder_File_Names): Change Ada bind file prefix on VMS from b$
64 * mlib-prj.adb: Change some Hostparm.OpenVMS checks to
65 Targparm.OpenVMS_On_Target.
66 ({declaration},Build_Library,Check_Library): Change Ada bind file
67 prefix on VMS from b$ to b__.
69 * osint-b.adb: Change some Hostparm.OpenVMS checks to
70 Targparm.OpenVMS_On_Target.
71 (Create_Binder_Output): Change Ada bind file prefix on VMS from b$ to
74 * targext.c: New file.
76 * Makefile.in: add support for vxworks653 builds
77 (../../vxaddr2line): gnatlink with targext.o.
78 (TOOLS_LIBS): Move targext.o to precede libgnat.
79 (init.o, initialize.o): Minor clean up in dependencies.
80 (GNATLINK_OBJS): Add targparm.o, snames.o
81 Add rules fo building targext.o and linking it explicitly with all
83 Also add targext.o to gnatlib.
85 * Make-lang.in: Add rules for building targext.o and linking it in
86 with gnat1 and gnatbind.
87 Add entry for exp_sel.o.
89 * osint.adb Change some Hostparm.OpenVMS checks to
90 Targparm.OpenVMS_On_Target.
91 (Object_File_Name): Use target object suffix.
93 * osint.ads (Object_Suffix): Remove, no longer used.
94 (Target_Object_Suffix): Initialize with target object suffix.
96 * rident.ads: Add special exception to license.
98 * targparm.adb (Get_Target_Parameters): Set the value of
99 Multi_Unit_Index_Character after OpenVMS_On_Target gets its definitive
101 (Get_Target_Parameters): Set OpenVMS_On_Target if openvms.
103 * targparm.ads: Add special exception to license.
105 * g-os_lib.ads, g-os_lib.adb (Get_Target_Debuggable_Suffix): New
107 (Copy_File): Make sure from file is closed if error on to file
108 (Get_Target_Executable_Suffix, Get_Target_Object_Suffix): New functions.
110 * make.adb (Object_Suffix): Intialize with Get_Target_Object_Suffix.
111 (Executable_Suffix): Intialize with Get_Target_Executable_Suffix.
113 * osint-c.adb (Set_Output_Object_File_Name): Initialize extension with
114 target object suffix.
116 2005-12-09 Jose Ruiz <ruiz@adacore.com>
117 Quentin Ochem <ochem@adacore.com>
118 Florian Villoing <villoing@adacore.com>
120 * a-taster.ads, a-taster.adb: New files.
122 * a-elchha.adb (Last_Chance_Handler): Change the task termination soft
123 link to the version that does nothing. This way the task termination
124 routine is not executed twice for the environment task when finishing
125 because of an unhandled exception.
127 * a-exextr.adb (Notify_Unhandled_Exception): Call the task termination
128 handler because of an unhandled exception.
130 * a-taside.adb (Abort_Tasks): Call the Abort_Tasks procedure from
131 System.Tasking.Utilities instead of that in System.Tasking.Stages.
133 * s-finimp.adb (initialization code): Modify the soft link for the
134 finalization of the global list instead of Adafinal.
136 * s-soflin.ads, s-soflin.adb (Task_Termination_NT): Add this
137 non-tasking version of the soft link for task termination. We do
138 nothing since if we are using the non-tasking version it
139 means that the task termination functionality is not used.
140 (Null_Finalize_Global_List): Add this null version for the procedure
141 in charge of finalizing the global list for controlled objects.
142 (Null_Adafinal): Remove this procedure. Adafinal_NT has been created
143 instead for handling run-time termination in a more flexible way.
144 (Adafinal_NT): This new procedure will take care of finalizing the
145 global list for controlled objects if needed, but no tasking
148 * s-tarest.adb (Task_Lock): Do not try to lock again the
149 Global_Task_Lock if we already own it. Otherwise, we get blocked in
150 some run-time operations.
151 (Task_Unlock): Do not try to actually unlock the Global_Task_Lock
152 until all nested locks have been released.
153 (Task_Wrapper): Call the fall-back task termination handler. It
154 applies to all tasks but the environment task.
155 (Finalize_Global_Tasks): Add the call for the task termination
156 procedure for the environment task.
157 (Task_Wrapper): suppress warnings around declaration of
158 Secondary_Stack_Address.
160 * s-tasini.adb (Final_Task_Unlock): Global_Task_Lock_Nesting has been
161 moved to the Common_ATCB record.
162 (Task_Lock): Global_Task_Lock_Nesting has been moved to the
164 (Task_Unlock): Global_Task_Lock_Nesting has been moved to the
167 * s-taskin.adb (Initialize_ATCB): Initialize Global_Task_Lock_Nesting,
168 Fall_Back_Handler, and Specific_Handler.
170 * s-taskin.ads (Cause_Of_Termination): Redefine this type here, already
171 defined in Ada.Task_Termination, to avoid circular dependencies.
172 (Termination_Handler): Redefine this type here, alredy defined in
173 Ada.Task_Termination, for avoiding circular dependencies.
174 (Common_ATCB): Add the Fall_Back_Handler and Specific_Handler required
175 for storing task termination handlers. In addition,
176 Global_Task_Lock_Nesting has been moved from Ada_Task_Control_Block to
177 Common_ATCB because it is used by both the regular and the restricted
179 (Ada_Task_Control_Block): Move Global_Task_Lock_Nesting from here to
180 Common_ATCB because it is used by both the regular and the restricted
182 (Common_ATCB): Added a dynamic task analyzer field.
184 * s-tassta.adb (Abort_Tasks): Move the code in charge of checking
185 potentially blocking operations to System.Tasking.Utilities.Abort_Tasks.
186 (Task_Wrapper): Call the task termination handler. It applies to all
187 tasks but the environment task.
188 (Finalize_Global_Tasks): Call the task termination procedure for the
189 environment task. The call to Finalize_Global_List is now performed
190 using the soft links mechanism.
191 (Task_Wrapper): added dynamic stack analysis.
193 * s-tasuti.adb (Abort_Tasks): The code in charge of checking
194 potentially blocking operations has been moved from
195 System.Tasking.Stages.Abort_Tasks to this procedure. There can be
196 direct calls to System.Tasking.Utilities.Abort_Tasks that do not pass
197 through System.Tasking.Stages.Abort_Tasks, and we do not want to miss
200 * s-solita.adb (Task_Termination_Handler_T): Add this task-safe version
201 of task termination procedure.
202 (Init_Tasking_Soft_Links): Install the task-safe version of the soft
203 link for the task termination procedure.
205 * bindusg.adb: (Bindusg): Added documentation for -u option.
207 * bindgen.adb (Get_Main_Ada) Added handling of dynamic stack analysis.
208 (Get_Main_C): Add handling of dynamic stack analysis.
209 (Gen_Output_File_C): Add external functions for dynamic stack analysis.
211 * Makefile.rtl: Add entry for a-taster (Ada.Task_Termination).
212 (GNATRTL_NONTASKING_OBJS) Added entries for dynamic stack analysis
213 (GNATRTL_NONTASKING_OBJS): Add AltiVec files.
215 * opt.ads: Added flags used by dynamic stack measurement.
216 (Max_Line_Length): Remove (not used anymore)
218 * s-io.ads, s-io.adb (Standard_Error): new subprogram
219 (Standart_Output): new subprogram
220 (Set_Output): new subprogram
221 (Put): now uses the value of Current_Out to know if the output has to be
222 send to stderr or stdout.
224 * s-stausa.ads: Complete implementation.
226 * switch-b.adb: Added handling of -u switch for dynamic stack analysis.
228 * impunit.adb (Non_Imp_File_Names_05): Add Ada.Task_Termination to the
229 list of Ada 05 files.
230 (GNAT Library Units): Add AltiVec files.
232 * g-allein.ads, g-alleve.adb, g-alleve.ads, g-altcon.adb,
233 g-altcon.ads, g-altive.ads, g-alveop.adb, g-alveop.ads
234 g-alvety.ads, g-alvevi.ads: New files providing altivec API.
236 2005-12-09 Nicolas Setton <setton@adacore.com>
238 * adaint.c (__gnat_locate_regular_file): Return immediately if
241 2005-12-09 Javier Miranda <miranda@adacore.com>
242 Hristian Kirtchev <kirtchev@adacore.com>
244 * a-tags.ads, a-tags.adb (Offset_To_Top): Moved from the package body
245 to the specification because the frontend generates code that uses this
247 (Set_Interface_Table): Add missing assertion.
248 Update documentation describing the run-time structure.
249 (Displace): New subprogram that displaces the pointer to the object
250 to reference one of its secondary dispatch tables.
251 (IW_Membership): Modified to use the new table of interfaces.
252 (Inherit_TSD): Modified to use the new table of interfaces.
253 (Register_Interface_Tag): Use the additional formal to fill the
254 contents of the new table of interfaces.
255 (Set_Interface_Table): New subprogram that stores in the TSD the
256 pointer to the table of interfaces.
257 (Set_Offset_To_Top): Use the additional formal to save copy of
258 the offset value in the table of interfaces.
259 Update structure of GNAT Primary and Secondary dispatch table diagram.
260 Add comment section on GNAT dispatch table prologue.
261 (Offset_To_Signature): Update the constant value of the Signature field.
262 (Dispatch_Table): Update comment on hidden fields in the prologue.
263 (Get_Entry_Index, Get_Prim_Op_Kind, Get_Offset_Index, OSD,
264 Set_Entry_Index, Set_Offset_Index, Set_Prim_Op_Kind, SSD, TSD): Change
265 the type of formal parameter T to Tag, introduce additional assertions.
266 (Get_Num_Prim_Ops, Set_Num_Prim_Ops): Remove an unnecessary type
268 (Get_Tagged_Kind, Set_Tagged_Kind): New bodies.
270 * exp_ch6.adb (Register_Interface_DT_Entry): Remove the Thunk_Id actual
271 in all the calls to Expand_Interface_Thunk. Instead of referencing the
272 record component containing the tag of the secondary dispatch table we
273 have to use the Offset_To_Top run-time function to get this information;
274 otherwise if the pointer to the base of the object has been displace
275 we get a wrong value if we use the 'position attribute.
277 * exp_disp.adb (Expand_Interface_Thunk): Remove the Thunk_Id actual in
278 all the calls to Expand_Interface_Thunk.
279 (Make_Secondary_DT): Secondary dispatch tables do not have a table of
280 interfaces; hence the call to Set_Interface_Table was clearly wrong.
281 (Collect_All_Interfaces): Modify the internal subprogram Collect to
282 ensure that the interfaces implemented by the ancestors are placed
283 at the header of the generated list.
284 (Expand_Interface_Conversion): Handle the case in which the displacement
285 associated with the interface conversion is not statically known. In
286 this case we generate a call to the new run-time subprogram Displace.
287 (Make_DT): Generate and fill the new table of interfaces.
288 (Ada_Actions, Action_Is_Proc, Action_Nb_Arg): Add entries for
289 Get_Tagged_Kind and Set_Tagged_Kind.
290 (Tagged_Kind): New function that determines the tagged kind of a type
291 with respect to limitedness and concurrency and returns a reference to
293 (Make_Disp_Asynchronous_Select_Body, Make_Disp_Conditional_Select_Body,
294 Make_Disp_Timed_Select_Body): Correctly retrieve the pointer to the
295 primary dispatch table for a type.
296 (Make_DT, Make_Secondary_DT): Set the tagged kind in the primary and
297 secondary dispatch table respectively of a tagged type.
299 * exp_disp.ads (Expand_Interface_Thunk): Remove Thunk_Id formal.
300 (Expand_Interface_Conversion): New subprogram to indicate if the
301 displacement of the type conversion is statically known.
302 (DT_Access_Action): Add values Get_Tagged_Kind and Set_Tagged_Kind.
304 * rtsfind.ads (RE_Offset_To_Top): New entity
305 (RTU_Id): Add Ada_Task_Termination to the list so that it is made
307 (Re_Displace): New entity
308 (RE_Interface_Data): New entity
309 (RE_Set_Interface_Data): New_Entity
310 (RE_Id, RE_Unit_Table): Add entry for RE_Get_Tagged_Kind,
311 Set_Tagged_Kind, RE_Tagged_Kind, RE_TK_Abstract_Limited_Tagged,
312 RE_TK_Abstract_Tagged, RE_TK_Limited_Tagged, RE_TK_Protected,
313 RE_TK_Tagged, RE_TK_Task.
315 * exp_ch3.adb (Init_Secondary_Tags): Modify the subprogram
316 Init_Secondary_Tags_Internal to allow its use with interface types and
317 also to generate the code for the new additional actual required
318 by Set_Offset_To_Top.
319 (Build_Init_Statements): In case of components associated with abstract
320 interface types there is no need to generate a call to its IP.
321 (Freeze_Record_Type): Generate Select Specific Data tables only for
323 (Make_Predefined_Primitive_Specs, Predefined_Primitive_Bodies): Generate
324 the bodies and specifications of the predefined primitive operations
325 dealing with dispatching selects and abort, 'Callable, 'Terminated only
326 for concurrent types.
328 * exp_sel.ads, exp_sel.adb: New files.
330 * exp_ch9.adb (Build_Protected_Entry, Expand_N_Protected_Body,
331 Expand_N_Protected_Type_Declaration, Make_Initialize_Protection): Handle
332 properly protected objects and attach handler in the case of the
334 Move embeded package Select_Expansion_Utilities into a separate external
336 (Expand_N_Asynchronous_Select, Expand_N_Conditional_Select,
337 Expand_N_Timed_Entry_Call): Correct calls external package Exp_Sel.
338 (Build_K, Build_S_Assignment): New subprograms, part of the select
340 (Expand_N_Asynchronous_Select, Expand_N_Conditional_Entry_Call,
341 Expand_N_Timed_Entry_Call): Optimize expansion of select statements
342 where the trigger is a dispatching procedure of a limited tagged type.
344 2005-12-09 Olivier Hainque <hainque@adacore.com>
346 * decl.c (gnat_to_gnu_entity, renaming object case): Don't early expand
347 pointer initialization values. Make a SAVE_EXPR instead. Add comments
348 about the use and expansion of SAVE_EXPRs in the various possible
349 renaming handling cases.
350 (components_to_record, compare_field_bitpos): Sort by DECL_UID, not by
351 abusing DECL_FCONTEXT.
353 2005-12-09 Matthew Heaney <heaney@adacore.com>
355 * a-convec.adb (Merge): Added assertions to check whether vector params
358 * a-coinve.adb (Merge): Added assertions to check whether vector params
361 * a-cohama.ads (Cursor'Write): raises Program_Error per latest AI-302
363 (Cursor'Read): raises PE
365 * a-cohama.adb (Insert.New_Node): Uses box-style syntax to init elem
366 to its default value.
368 * a-cihama.adb: Manually check whether cursor's key and elem are
371 * a-cidlli.ads, a-cidlli.adb (Splice): Changed param name and param mode
372 (Merge): Assert that target and source lists are in order
373 (Swap): Declare non-const temporaries, to pass to Splice
375 * a-cdlili.ads: (Splice): Changed param name and param mode
377 * a-cdlili.adb: (Splice): Changed param name and param mode
378 (Merge): Assert that target and source lists are in order
379 (Swap): Declare non-const temporaries, to pass to Splice
381 * a-ciorma.ads, a-coorma.ads: (Read): declare Stream param as not null
382 (Write): declare Stream param as not null
384 * a-ciorma.adb, a-coorma.adb: All explicit raise statements now include
385 an exception message.
387 2005-12-09 Thomas Quinot <quinot@adacore.com>
388 Robert Dewar <dewar@adacore.com>
390 * hostparm.ads (Max_Line_Length): Set to Types.Column_Number'Last - 1,
391 which is the absolute maximum length we can support.
393 * frontend.adb: For the processing of configuration pragma files,
394 remove references to Opt.Max_Line_Length, which is not checked anymore.
396 * namet.ads (Name_Buffer): Adjust size to reflect increase on max line
400 Always check line length against the absolute supported maximum,
401 Hostparm.Max_Line_Length.
403 * stylesw.adb (Set_Style_Check_Options, case M): The maximum supported
404 value for the maximum line length is Max_Line_Length (not
406 Minor error msg update
407 (Set_Style_Check_Options): New interface returning error msg
408 Minor code reorganization (processing for 'M' was out of alpha order)
410 * switch-c.adb: New interface for Set_Style_Check_Options
412 * stylesw.ads (Set_Style_Check_Options): New interface returning error
415 2005-12-09 Javier Miranda <miranda@adacore.com>
417 * exp_aggr.adb (Build_Record_Aggr_Code): Default-initialialized records
418 with IP subprogram were only supported if there were limited types.
420 * sem_aggr.adb (Resolve_Record_Aggregate): Default-initialialized
421 records with IP subprogram were only supported if there were limited
424 2005-12-09 Olivier Hainque <hainque@adacore.com>
425 Eric Botcazou <ebotcazou@adacore.com>
427 * trans.c (tree_transform, emit_check): Adjust calls to
428 build_call_raise, passing the now expected GNAT_NODE argument.
430 * gigi.h (build_call_raise): Add a GNAT_NODE argument to convey better
431 source line information than what the current global locus indicates
434 * utils2.c (build_simple_component_ref): Return 0 if the offset of the
435 field has overflowed.
436 (build_call_raise): Add a GNAT_NODE argument to convey better source
437 line information than what the current global locus indicates when
439 (build_component_ref): Adjust call to build_call_raise.
441 2005-12-09 Pascal Obry <obry@adacore.com>
443 * g-diopit.adb (Find): Fix test to exit the iterator and make sure that
444 the iterator is quitting iteration on parent directory.
446 2005-12-09 Javier Miranda <miranda@adacore.com>
448 * exp_ch5.adb (Expand_N_Assignment_Statement): In case of tagged types
449 and the assignment to a class-wide object, before the assignment we
450 generate a run-time check to ensure that the tag of the Target is
451 covered by the tag of the source.
453 2005-12-09 Robert Dewar <dewar@adacore.com>
455 * exp_imgv.adb (Expand_Image_Attribute): Generate extra boolean
456 parameter in call to Image_Wide_Character.
458 * s-imgwch.ads, s-imgwch.adb (Image_Wide_Character): Add boolean
459 parameter Ada_2005 to deal with annoying FFFE/FFFF inconsistency.
460 (Image_Wide_Character): Add boolean parameter Ada_2005 to deal with
461 annoying FFFE/FFFF inconsistency.
463 2005-12-09 Robert Dewar <dewar@adacore.com>
464 Javier Miranda <miranda@adacore.com>
465 Ed Schonberg <schonberg@adacore.com>
467 * exp_util.ads, exp_util.adb (Is_Ref_To_Bit_Packed_Slice): Handle case
469 (Find_Interface): New subprogram that given a tagged type and one of its
470 component associated with the secondary table of an abstract interface
471 type, return the entity associated with such abstract interface type.
472 (Make_Subtype_From_Expr): If type has unknown discriminants, always use
473 base type to create anonymous subtype, because entity may be a locally
474 declared subtype or generic actual.
475 (Find_Interface): New subprogram that given a tagged type and one of its
476 component associated with the secondary table of an abstract interface
477 type, return the entity associated with such abstract interface type.
479 * sem_res.adb (Resolve_Type_Conversion): Handle the case in which the
480 conversion cannot be handled at compile time. In this case we pass this
481 information to the expander to generate the appropriate code.
483 2005-12-09 Robert Dewar <dewar@adacore.com>
484 Ed Schonberg <schonberg@adacore.com>
485 Gary Dismukes <dismukes@adacore.com>
486 Javier Miranda <miranda@adacore.com>
487 Hristian Kirtchev <kirtchev@adacore.com>
489 * einfo.adb (Itype_Printed): New flag
490 (Is_Limited_Type): Derived types do not inherit limitedness from
491 interface progenitors.
492 (Is_Return_By_Reference_Type): Predicate does not apply to limited
495 * einfo.ads (Itype_Printed): New flag
496 Move Is_Wrapper_Package to proper section
497 Add missing Inline for Is_Volatile
499 * output.ads, output.adb (Write_Erase_Char): New procedure
500 (Save/Restore_Output_Buffer): New procedures
501 (Save/Restore_Output_Buffer): New procedures
503 * sprint.ads, sprint.adb (Write_Itype): Handle case of record itypes
504 Add missing support for anonymous access type
505 (Write_Id): Insert calls to Write_Itype
506 (Write_Itype): New procedure to output itypes
508 * par-ch12.adb (P_Formal_Derived_Type_Definition): In Ada 2005, handle
509 use of "limited" in declaration.
511 * sinfo.ads, sinfo.adb:
512 Formal derived types can carry an explicit "limited" indication.
514 * sem_ch3.adb: Add with and use of Targparm.
515 (Create_Component): If Frontend_Layout_On_Target is True and the
516 copied component does not have a known static Esize, then reset
517 the size and positional fields of the new component.
518 (Analyze_Component_Declaration): A limited component is
519 legal within a protected type that implements an interface.
520 (Collect_Interfaces): Do not add to the list the interfaces that
521 are implemented by the ancestors.
522 (Derived_Type_Declaration): If the parent of the full-view is an
523 interface perform a transformation of the tree to ensure that it has
524 the same parent than the partial-view. This simplifies the job of the
525 expander in order to generate the correct object layout, and it is
526 needed because the list of interfaces of the full-view can be given in
528 (Process_Full_View): The parent of the full-view does not need to be
529 a descendant of the parent of the partial view if both parents are
531 (Analyze_Private_Extension_Declaration): If declaration has an explicit
532 "limited" the parent must be a limited type.
533 (Build_Derived_Record_Type): A derived type that is explicitly limited
534 must have limited ancestor and progenitors.
535 (Build_Derived_Type): Ditto.
536 (Process_Full_View): Verify that explicit uses of "limited" in partial
537 and full declarations are consistent.
538 (Find_Ancestor_Interface): Remove function.
539 (Collect_Implemented_Interfaces): New procedure used to gather all
540 implemented interfaces by a type.
541 (Contain_Interface): New function used to check whether an interface is
543 (Find_Hidden_Interface): New function used to determine whether two
544 lists of interfaces constitute a set equality. If not, the first
545 differing interface is returned.
546 (Process_Full_View): Improve the check for the "no hidden interface"
547 rule as defined by AI-396.
549 2005-12-09 Robert Dewar <dewar@adacore.com>
551 * freeze.adb (Freeze_Record_Type): Only test for useless pack on record
552 types, not on record subtypes.
553 (Freeze_Entity): Code cleanup. Add barrier to the loop
554 that generates the references for primitive operations. This allows to
555 remove an unnecessary exception handler.
556 Code reformatting and comment clean ups.
558 2005-12-09 Vincent Celier <celier@adacore.com>
560 * gnatcmd.adb (GNATCmd): GNAT CHECK accepts switch -U
561 If GNAT CHECK is called with a project file, but with no
562 source on the command line, call gnatcheck with all the compilable
563 sources of the project.
564 Take into account the new command Check, for gnatcheck. Treat as for
565 other ASIS tools: take into account project, specific package Check and
567 For ASIS tools, add the switches in package Compiler for
568 the invocation of the compiler.
570 * prj-attr.adb: Add package Check and its attributes
572 * vms_conv.ads (Command_Type): New command Check, for gnatcheck
574 * vms_conv.adb (Initialize): Change Params of command Check to
576 Change some Hostparm.OpenVMS checks to Targparm.OpenVMS_On_Target.
577 Add data for new command Check
579 * vms_data.ads: Add project related qualifiers for GNAT CHECK and GNAT
581 Add qualifiers for Check command options
582 (Command_Type): New command Check
584 2005-12-09 Thomas Quinot <quinot@adacore.com>
586 * mlib-utl.adb (Ar): Use Output.Buffer_Max to determine whether a
587 command line switch overruns the output buffer.
589 2005-12-09 Robert Dewar <dewar@adacore.com>
591 * sem_prag.adb: Processing for new pragma Complete_Representation
592 (Analyze_Pragma, case Debug): Implement two argument form.
594 * par-prag.adb: Entry for new pragma Complete_Representation
595 (Prag, case Debug): Recognize two argument form of pragma Debug
596 New interface for Set_Style_Check_Options.
598 * sem_ch13.adb: Implement new pragma Complete_Representation.
600 * snames.adb, snames.ads, snames.h: Entry for new pragma
601 Complete_Representation.
603 2005-12-09 Gary Dismukes <dismukes@adacore.com>
605 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Revise test for
606 available user-specified stream attributes on limited parameters to
607 also test the type directly rather than only its underlying type (for
608 Ada 95) and, in the case of Ada 2005, to check that the user-specified
609 attributes are visible at the point of the subprogram declaration.
610 For Ada 2005, the error message is modified to indicate that the
611 type's stream attributes must be visible (again, only for -gnat05).
613 2005-12-09 Ed Schonberg <schonberg@adacore.com>
615 * sem_ch12.adb (Subtypes_Match): Handle properly Ada05 arrays of
616 anonymous access types.
618 * sem_eval.adb (Subtypes_Statically_Match): Implement new rules for
619 matching of anonymous access types and anonymous access to subprogram
620 types. 'R'M 4.9.1 (2/2).
622 2005-12-09 Ed Schonberg <schonberg@adacore.com>
624 * sem_ch4.adb (Remove_Abstract_Operations): Do not apply preference
625 rule prematurely when operands are universal, remaining ambiguities
626 will be removed during resolution.
629 * sem_type.adb (Disambiguate): In Ada95 mode, discard interpretations
630 that are Ada 2005 functions.
631 (Has_Abstract_Interpretation): Subsidiary to
632 Remove_Conversions, to remove ambiguities caused by abstract operations
633 on numeric types when operands are universal.
635 2005-12-09 Robert Dewar <dewar@adacore.com>
637 * sem_ch6.adb (Analyze_Subprogram_Body): Properly check categorization
638 for case where spec is categorized.
640 2005-12-09 Javier Miranda <miranda@adacore.com>
642 * sem_ch8.adb (Find_Type): In case of tagged types that are concurrent
643 types use the corresponding record type. This was not needed before
644 the implementation of Ada 2005 synchronized types because
645 concurrent types were never tagged types in Ada 95.
647 2005-12-09 Ed Schonberg <schonberg@adacore.com>
649 * sem_ch9.adb (Analyze_Delay_Alternative, Analyze_Delay_Until): Use the
650 first subtype of the type of the expression to verify that it is a
653 2005-12-09 Robert Dewar <dewar@adacore.com>
655 * sem_util.ads, sem_util.adb (Full_Qualified_Name): Now provides
658 2005-12-09 Quentin Ochem <ochem@adacore.com>
659 Robert Dewar <dewar@adacore.com>
660 Ed Falis <falis@adacore.com>
661 Florian Villoing <villoing@adacore.com>
662 Thomas Quinot <quinot@adacore.com>
663 Arnaud Charlet <charlet@adacore.com>
665 * gnat_ugn.texi: Created section "Stack Related Tools"
666 Moved "Stack Overflow Checking" subsection from "Switches for gcc" to
667 "Stack Related Tools"
668 Added subsection "Static Stack Usage Analysis"
669 Added subsection "Dynamic Stack Usage Analysis"
670 Include documentation of itypes in sprint listing (-gnatG)
671 Documented gnatbind -D switch (default sec stack size for fixed sec
673 Added Interrupt_State and Persistent_BSS to list of configuration
675 Add missing doc for maximum value of nnn in -gnatyMnnn
677 * gnat_rm.texi: Document the AltiVec binding.
678 Add documentation for pragma Complete_Representation
679 Shortened an overly long line (> 79 chars)
680 Clarify documentation of unchecked conversion in implementation
682 Document two argument form of pragma Debug
684 * types.ads (Column_Number): Update documentation.
686 * exp_ch7.ads (Make_Adjust_Call): Document the special processing for
687 library level Finalize_Storage_Only objects (these are not attached to
688 any finalization list).
690 * system-mingw.ads: (Underlying_Priorities): Update comment.
692 2005-12-09 Robert Dewar <dewar@adacore.com>
694 * i-c.adb, i-cexten.ads, i-cobol.adb, i-cobol.ads, i-cpoint.ads,
695 i-cpp.adb, i-cpp.ads, i-cstrea.ads, i-cstrin.adb, i-cstrin.ads,
696 inline.adb, interfac.ads, i-os2err.ads, i-os2lib.ads, i-os2syn.ads,
697 i-os2thr.ads, itypes.adb, itypes.adb, itypes.ads, krunch.ads,
698 krunch.adb, lib.adb, lib.ads, lib-list.adb, lib-load.adb,
699 lib-load.ads, lib-sort.adb, live.adb, make.ads, i-cstrea-vms.adb,
700 interfac-vms.ads, makegpr.adb, indepsw-gnu.adb, indepsw.ads,
701 s-wchcon.ads, sdefault.ads, sem_ch10.adb, sem_eval.ads: Minor
704 2005-12-09 Robert Dewar <dewar@adacore.com>
706 * s-vaflop-vms-alpha.adb: (Ne_F): New function
709 * exp_ch4.adb (Expand_Allocator_Expression): Factor duplicated code
711 (Rewrite_Comparison): Handle case where operation is not a comparison
712 and ignore, and also handle type conversion case.
714 2005-12-09 Thomas Quinot <quinot@adacore.com>
716 * exp_aggr.ads: Fix typo in comment.
717 ???-mark Convert_Aggr_In_Assignment as needing documentation.
719 2005-12-09 Gary Dismukes <dismukes@adacore.com>
721 * layout.adb: Replace various uses of byte by storage unit throughout.
722 (Get_Max_SU_Size): Name changed from Get_Max_Size. In the case of a
723 static size, convert to storage units before returning, to conform to
726 2005-12-09 Matthew Gingell <gingell@adacore.com>
728 * g-exctra.ads: Fix typo in comment.
730 2005-12-09 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
732 * utils.c: Minor reformatting.
734 2005-12-09 Robert Dewar <dewar@adacore.com>
737 Further comment fixes to make the status of the default file clear
739 * s-bitops.adb: Clarify comment for Bits_Array
741 2005-12-07 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
743 * Make-lang.in (ada.install-normal): Remove.
745 2005-12-07 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
747 * Make-lang.in: Remove all dependencies on s-gtype.
749 2005-12-05 Richard Guenther <rguenther@suse.de>
751 * utils.c (convert): Use fold_convert where appropriate.
753 2005-12-05 Paolo Bonzini <bonzini@gnu.org>
755 * Makefile.in (gnatlib): Fix regex, using \. instead of . when
758 2005-12-02 Richard Guenther <rguenther@suse.de>
760 * trans.c (gnat_gimplify_expr): Use buildN instead of build.
762 2005-12-01 Roger Sayle <roger@eyesopen.com>
764 * utils.c (max_size): Only test for TREE_OVERFLOW on INTEGER_CST
767 2005-11-23 Laurent GUERBY <laurent@guerby.net>
769 * mlib-prj.adb (Build_Library): Initialize Delete.
771 2005-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>
773 * socket.c: Add extern int h_errno for rtems since networking header
774 files are not available at this point in a tool bootstrap. Newlib
775 only has basic C library header files.
777 2005-11-19 Richard Guenther <rguenther@suse.de>
778 Roger Sayle <roger@eyesopen.com>
781 * misc.c (internal_error_function): Don't use vsprintf to format
782 the error message text, instead use pp_format_text and the new
783 pretty printer APIs. This allows handling of %qs, %w, etc.
785 2005-11-18 Laurent GUERBY <laurent@guerby.net>
788 * Makefile.in: Use s-auxdec-empty for RTEMS.
790 2005-11-17 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
793 * trans.c (gnat_gimplify_expr, case ADDR_EXPR): Always make
794 a temporary if taking the address of something that is neither
795 reference, declaration, or constant, since the gimplifier
796 can't handle that case.
798 2005-11-17 Laurent GUERBY <laurent@guerby.net>
801 * s-auxdec-empty.ads, s-auxdec-empty.adb: New files.
803 2005-11-16 Richard Guenther <rguenther@suse.de>
805 * Makefile.in: Add EH_MECHANISM=-gcc to s390(x) linux.
807 2005-11-16 Joel Sherrill <joel.sherrill@oarcorp.com>
810 * raise-gcc.c: Add missing stdarg.h include.
812 2005-11-16 Richard Guenther <rguenther@suse.de>
814 * Make-lang.in (ada/decl.o): Add $(EXPR_H) dependency.
815 (ada/misc.o): Likewise.
817 2005-11-14 Thomas Quinot <quinot@adacore.com>
819 * g-soccon.ads: Minor reformatting. Update comments.
821 * gsocket.h: Include <sys/times.h> in the VxWorks case, in order to
822 gain visibility on the declaration of struct timeval.
824 * g-soccon-freebsd.ads,
830 g-soccon-solaris.ads,
833 g-soccon-vxworks.ads (SIZEOF_tv_sec, SIZEOF_tv_usec): New constants.
835 * g-soccon-hpux-ia64.ads, g-soccon-linux-ppc.ads,
836 g-soccon-solaris-64.ads, g-soccon-linux-64.ads,
837 g-soccon-linux-x86.ads: New files.
839 * g-socthi-mingw.adb:
840 (Socket_Error_Message): Remove redundant use of GNAT.Sockets.Constants
842 * g-socthi-vxworks.ads, g-socthi-vms.ads, g-socthi-mingw.ads
843 (time_t, suseconds_t): New types constructed to match the tv_sec
844 and tv_usec fields of C struct timeval.
845 (Timeval): Construct structure in terms of the new types.
846 (Host_Errno): New function (imported from socket.c), returns last hosts
849 * g-socthi-vxworks.adb: Add error handling circuitry.
851 * g-socket.ads, g-socket.adb (To_Timeval): Reflect change of type for
852 components of struct timeval.
853 (Get_Host_By_Name, Get_Host_By_Address): Fix error reporting circuitry.
854 (Check_Selector): In error conditions, clear internal socket sets to
856 (Get_Socket_Option, Set_Socket_Option): Support for Multicast_If,
857 Send_Timeout, Receive_Timeout.
859 * g-socthi.ads (time_t, suseconds_t): New types constructed to match
860 the tv_sec and tv_usec fields of C struct timeval.
861 (Timeval): Construct structure in terms of the new types.
862 (Host_Errno): New function (imported from socket.c), returns last hosts
865 * socket.c (__gnat_get_h_errno): New function to retrieve h_errno, the
866 hosts database last error code.
868 * gen-soccon.c: Complete value expansion should not be performed on
869 TARGET, as it has the form of a math expression, and some components
870 may be platform-defined macros.
871 For VxWorks, generate the OK and ERROR values.
872 New constants giving the sizes of the components of C struct timeval.
874 2005-11-14 Robert Dewar <dewar@adacore.com>
875 Ed Schonberg <schonberg@adacore.com>
879 * types.ads: Include All_Checks in Suppress_Array
881 * checks.adb (Check_Needed): Remove kludge for a/=b rewritten as
882 not(a=b), since we no longer do this rewriting, and hence it is not
884 (Elaboration_Checks_Suppressed): Add special casing to
885 deal with different cases of static and dynamic elaboration checks (all
886 checks does not count in the first case, but does in the second).
887 (Expr_Known_Valid): Do not assume that the result of any arbitrary
888 function call is valid, since this is not the case.
889 (Ensure_Valid): Do not apply validity check to a real literal
890 in a universal or fixed context
892 * exp_ch4.adb (Expand_N_Op_Ne): Don't expand a/=b to not(a=b) for
893 elementary types using the operator in standard. It is cleaner not to
894 modify the programmers intent, especially in the case of floating-point.
895 (Rewrite_Comparison): Fix handling of /= (this was always wrong, but
896 it did not matter because we always rewrote a/=b to not(a=b).
897 (Expand_Allocator_Expression): For an allocator expression whose nominal
898 subtype is an unconstrained packed type, convert the expression to its
899 actual constrained subtype.
900 Implement warning for <= or >= where < or > not possible
901 Fix to Vax_Float tests (too early in many routines, causing premature
902 Vax_Float expansions.
904 * sem_prag.adb (Analyze_Pragma, case Obsolescent): Allow this pragma
905 to be used with packages and generic packages as well as with
907 (Suppress): Set All_Checks, but not Elaboration_Check, for case
908 of pragma Suppress (All_Checks)
909 (Analyze_Pragma, case Warnings): Implement first argument allowed to be
910 a string literal for precise control over warnings.
911 Avoid raise of pragma in case of unrecognized pragma and just return
914 * sem_prag.ads: Minor reformatting
916 * switch-c.adb (Scan_Front_End_Switches): Replace "raise Bad_Switch;"
917 with call to new procedure Bad_Switch. Call Scan_Pos with new parameter
918 Switch. Do not handle any exception.
919 Include -gnatwx as part of -gnatg (warn on redundant parens)
920 Allow optional = after -gnatm
921 (Scan_Front_End_Switches): The -gnatp switch sets All_Checks, but no
922 longer sets Elaboration_Checks.
923 Code to set warning mode moved to Sem_Warn
924 so that it can be shared by pragma processing.
926 * s-mastop-tru64.adb (Pop_Frame): Remove redundant parentheses in if
929 * s-taprop-solaris.adb:
930 Change some <= to =, to avoid new warning
932 * a-exexda.adb, prj-proc.adb:
933 Fix obvious typo (Num_Tracebacks compared <= 0 instead of < 0)
934 Fix obvious typo (Total_Errors_Detected <= 0 should be = 0)
936 2005-11-14 Robert Dewar <dewar@adacore.com>
938 * exp_vfpt.adb: Handle /= case
939 (Expand_Vax_Conversion): Properly recognize Conversion_OK flag
940 so that we do not get duplicate scaling for fixed point conversions.
942 * s-vaflop.ads, s-vaflop.adb: (Ne_F): New function
944 2005-11-14 Matthew Gingell <gingell@adacore.com>
946 * system-lynxos-ppc.ads, system-lynxos-x86.ads:
947 Increase default priority on Lynx from 15 to 17, and meet the Ada
948 requirement that Default_Priority be ((Priority'First +
949 Priority'Last) / 2) by increasing the range of Interrupt_Priority.
951 2005-11-14 Vincent Celier <celier@adacore.com>
953 * mlib-tgt-tru64.adb, mlib-tgt-aix.adb, mlib-tgt-irix.adb,
954 mlib-tgt-hpux.adb, mlib-tgt-hpux.adb, mlib-tgt-linux.adb,
955 mlib-tgt-solaris.adb, mlib-tgt-vms-alpha.adb, mlib-tgt-vms-alpha.adb,
956 mlib-tgt-vms-ia64.adb, mlib-tgt-mingw.adb, mlib-tgt-vxworks.adb,
957 mlib-tgt-darwin.adb, mlib-tgt.adb, mlib-tgt.ads,
958 mlib-tgt-lynxos.adb (DLL_Prefix): New function
960 2005-11-14 Doug Rupp <rupp@adacore.com>
962 * system-vms.ads, system-vms_64.ads: ADA$GNAT: New exported object in
965 2005-11-14 Arnaud Charlet <charlet@adacore.com>
967 * s-traces-default.adb, s-trafor-default.ads,
968 s-tratas-default.adb: Fix compilation errors.
970 2005-11-14 Jose Ruiz <ruiz@adacore.com>
972 * s-taprop-posix.adb (Initialize_Lock): Destroy mutex attribute before
973 raising the exception so the memory used is freed.
975 2005-11-14 Arnaud Charlet <charlet@adacore.com>
977 * adaint.h, adaint.c (__gnat_is_cross_compiler): New constant.
978 (Gnat_Install_Locks, __gnatlib_install_locks): Removed, no longer used.
979 (convert_address): Update comments and list of platforms using this.
981 * s-tasini.adb (Gnat_Install_Locks, __gnatlib_install_locks): Removed,
984 2005-11-14 Pascal Obry <obry@adacore.com>
985 Vincent Celier <celier@adacore.com>
987 * gnatdll.adb (Parse_Command_Line): Remove redundant use of
990 * memroot.adb: Remove redundant with/use clause on
991 System.Storage_Elements.
993 2005-11-14 Arnaud Charlet <charlet@adacore.com>
995 * a-except.adb (Zero_Cost_Exceptions): Removed, no longer used.
996 (builtin_longjmp, Process_Raise_Exceeption): Move setjmp/longjmp
997 related code to a-exexpr.adb
998 (Save_Occurrence_And_Private): Move GCC EH related code to
1000 (Raise_Current_Excep): Add new variable Id with pragma
1001 volatile, to ensure that the variable lives on stack.
1003 * a-exexpr-gcc.adb, raise-gcc.c: New file.
1005 * a-exexpr.adb (builtin_longjmp, Propagate_Exception): Moved here code
1007 Move GCC EH related code to a-exexpr-gcc.adb
1009 * Makefile.in: Add or update g-soccon LIBGNAT pairs for Linux/PPC and
1011 Split the Linux version of g-soccon into separate variants for 32 and 64
1013 (gnatlib): Use $(AR_FOR_TARGET) and $(RANLIB_FOR_TARGET)
1014 vice $(AR) and $(RANLIB). Remove use of host variable $(RANLIB_FLAGS).
1015 install-gnatlib: Use $(RANLIB_FOR_TARGET) vice $(RANLIB). Remove use
1016 of host variable $(RANLIB_FLAGS).
1017 (alpha64-dec-*vms*): Fix translations for 64 bit compiler.
1018 Code clean up: remove unused/obsolete targets.
1019 (EH_MECHANISM): New variable introduced to differenciate between the
1020 two EH mechanisms statically.
1021 (gnatlib-zcx, gnatlib-sjlj): Force EH_MECHANISM manually.
1022 (LIBGNAT_OBJS): Add raise-gcc.o
1023 (LIBGNAT_TARGET_PAIRS for ppc-vxworks): Use an specialized version of
1024 s-osinte.adb, s-tpopsp.adb, and system.ads for the run time that
1025 supports VxWorks 6 RTPs.
1026 (EXTRA_GNATRTL_NONTASKING_OBJS for ppc-vxworks): Remove the use of
1027 i-vxworks and i-vxwoio from the run time that supports VxWorks 6 RTPs.
1029 * raise.c: Move all GCC EH-related routines to raise-gcc.c
1031 2005-11-14 Jose Ruiz <ruiz@adacore.com>
1033 * s-tassta.adb (Create_Task): Move the code in charge of resetting the
1034 deferral level, when abort is not allowed, to a later stage (the
1036 (Task_Wrapper): If Abort is not allowed, reset the deferral level since
1037 it will not get changed by the generated code. It was previously done
1040 2005-11-14 Thomas Quinot <quinot@adacore.com>
1041 Olivier Hainque <hainque@adacore.com>
1042 Eric Botcazou <ebotcazou@adacore.com>
1045 Factor common code to build a storage type for an unconstrained object
1046 from a fat or thin pointer type and a constrained object type.
1047 (annotate_value): Handle BIT_AND_EXPR.
1048 (annotate_rep): Don't restrict the back annotation of inherited
1049 components to the type_annotate_only case.
1050 (gnat_to_gnu_entity) <E_Array_Type>: Do not invoke create_type_decl if
1051 we are not defining the type.
1052 <E_Record_Type>: Likewise.
1053 (gnat_to_gnu_entity) <object, renaming>: Adjust comments and structure
1054 to get advantage of the new maybe_stabilize_reference interface, to
1055 ensure that what we reference is indeed stabilized instead of relying
1056 on assumptions on what the stabilizer does.
1057 (gnat_to_gnu_entity) <E_Incomplete_Type>: If the entity is an incomplete
1058 type imported through a limited_with clause, use its non-limited view.
1059 (Has_Stdcall_Convention): New macro, to centralize the Windows vs others
1061 (gnat_to_gnu_entity): Use Has_Stdcall_Convention instead of a spread mix
1062 of #if sections + explicit comparisons of convention identifiers.
1063 (gnat_to_gnu_entity) <E_Variable>: Decrement force_global if necessary
1064 before early-returning for certain types when code generation is
1066 (gnat_to_gnu_entity) <object>: Adjust comment attached to the
1067 nullification of gnu_expr we do for objects with address clause and
1068 that we are not defining.
1069 (elaborate_expression_1): Do not create constants when creating
1070 variables needed by the debug info: the dwarf2 writer considers that
1071 CONST_DECLs is used only to represent enumeration constants, and emits
1073 (gnat_to_gnu_entity) <object>: When turning a non-definition of an
1074 object with an address clause into an indirect reference, drop the
1075 initializing expression.
1077 (STACK_CHECK_BUILTIN): Delete.
1078 (STACK_CHECK_PROBE_INTERVAL): Likewise.
1079 (STACK_CHECK_MAX_FRAME_SIZE): Likewise.
1080 (STACK_CHECK_MAX_VAR_SIZE): Likewise.
1081 (gnat_to_gnu_entity): If gnat_entity is a renaming, do not mark the tree
1082 corresponding to the renamed object as ignored for debugging purposes.
1084 * trans.c (tree_transform, case N_Attribute_Reference, case Attr_Size &
1085 related): For a prefix that is a dereference of a fat or thin pointer,
1086 if there is an actual subtype provided by the front-end, use that
1087 subtype to build an actual type with bounds template.
1088 (tree_transform, case N_Free_Statement): If an Actual_Designated_Subtype
1089 is provided by the front-end, use that subtype to compute the size of
1090 the deallocated object.
1091 (gnat_to_gnu): When adding a statement into an elaboration procedure,
1092 check for a potential violation of a No_Elaboration_Code restriction.
1093 (maybe_stabilize_reference): New function, like gnat_stabilize_reference
1094 with extra arguments to control whether to recurse through non-values
1095 and to let the caller know if the stabilization has succeeded.
1096 (gnat_stabilize_reference): Now a simple wrapper around
1097 maybe_stabilize, for common uses without restriction on lvalues and
1098 without need to check for the success indication.
1099 (gnat_to_gnu, call_to_gnu): Adjust calls to gnat_stabilize_reference, to
1100 pass false instead of 0 as the FORCE argument which is a bool.
1101 (Identifier_to_gnu): Remove checks ensuring that an renamed object
1102 attached to a renaming pointer has been properly stabilized, as no such
1103 object is attached otherwise.
1104 (call_to_gnu): Invoke create_var_decl to create the temporary when the
1105 function uses the "target pointer" return mechanism.
1106 Reinstate conversion of the actual to the type of the formal
1107 parameter before any other specific treatment based on the passing
1108 mechanism. This turns out to be necessary in order for PLACEHOLDER
1109 substitution to work properly when the latter type is unconstrained.
1111 * gigi.h (build_unc_object_type_from_ptr): New subprogram, factoring a
1113 (maybe_stabilize_reference): New function, like gnat_stabilize_reference
1114 with extra arguments to control whether to recurse through non-values
1115 and to let the caller know if the stabilization has succeeded.
1117 * utils2.c (gnat_build_constructor): Only sort the fields for possible
1118 static output of record constructor if all the components are constant.
1119 (gnat_build_constructor): For a record type, sort the list of field
1120 initializers in increasing bit position order.
1121 Factor common code to build a storage type for an unconstrained object
1122 from a fat or thin pointer type and a constrained object type.
1123 (build_unary_op) <ADDR_EXPR>: Always recurse down conversions between
1124 types variants, and process special cases of VIEW_CONVERT expressions
1125 as their NOP_EXPR counterpart to ensure we get to the
1126 CORRESPONDING_VARs associated with CONST_DECls.
1127 (build_binary_op) <MODIFY_EXPR>: Do not strip VIEW_CONVERT_EXPRs
1128 on the right-hand side.
1130 * utils.c (build_unc_object_type_from_ptr): New subprogram, factoring
1132 (convert) <VIEW_CONVERT_EXPR>: Return the inner operand directly if we
1133 are converting back to its original type.
1134 (convert) <JM input>: Fallthrough regular conversion code instead of
1135 extracting the object if converting to a type variant.
1136 (create_var_decl): When a variable has an initializer requiring code
1137 generation and we are at the top level, check for a potential violation
1138 of a No_Elaboration_Code restriction.
1139 (create_var_decl): call expand_decl for CONST_DECLs, to set MODE, ALIGN
1140 SIZE and SIZE_UNIT which we need for later back-annotations.
1141 * utils.c: (convert) <STRING_CST>: Remove obsolete code.
1142 <VIEW_CONVERT_EXPR>: Do not lift the conversion if the target type
1143 is an unchecked union.
1144 (pushdecl): Set DECL_NO_STATIC_CHAIN on imported nested functions.
1145 (convert) <VIEW_CONVERT_EXPR>: When the types have the same
1146 main variant, just replace the VIEW_CONVERT_EXPR.
1147 <UNION_TYPE>: Revert 2005-03-02 change.
1149 * repinfo.h, repinfo.ads: Add tcode for BIT_AND_EXPR.
1151 * repinfo.adb (Print_Expr, Rep_Value): Handle Bit_And_Expressions.
1153 2005-11-14 Matthew Heaney <heaney@adacore.com>
1155 * a-crbtgo.ads, a-crbtgo.adb, a-coorse.ads, a-coorse.adb, a-convec.ads,
1156 a-convec.adb, a-coinve.ads, a-coinve.adb, a-cohama.ads, a-cohama.adb,
1157 a-ciorse.ads, a-ciorse.adb, a-cihama.ads, a-cihama.adb, a-cidlli.ads,
1158 a-cidlli.adb, a-cdlili.ads, a-cdlili.adb, a-coormu.adb, a-ciormu.adb,
1159 a-cihase.adb, a-cihase.ads, a-cohase.adb, a-cohase.ads, a-ciorma.ads,
1160 a-coorma.ads, a-ciormu.ads, a-coormu.ads, a-ciorma.adb, a-coorma.adb:
1161 Compiles against the spec for ordered maps described in sections
1162 A.18.6 of the most recent (August 2005) AI-302 draft.
1164 2005-11-14 Olivier Hainque <hainque@adacore.com>
1166 * cuintp.c (UI_To_gnu): Use a proper type for intermediate computations
1167 to ensure bias adjustments take place when need be and to prevent
1168 occurrences of intermediate overflows.
1170 2005-11-14 Matthew Gingell <gingell@adacore.com>
1171 Olivier Hainque <hainque@adacore.com>
1173 * tb-gcc.c (trace_callback): Work around problem with _Unwind_GetIP on
1176 * tracebak.c (ia64 configuration): Enable _Unwind_Backtrace driven
1177 tracebacks on ia64 HP-UX and provide explanatory comment.
1178 Enable backtraces on ia64 GNU/Linux.
1179 (x86 configuration): Bump FRAME_LEVEL to 1 to ensure we retrieve a real
1180 base pointer from builtin_frame_address. Adjust BASE_SKIP accordingly.
1182 2005-11-14 Hristian Kirtchev <kirtchev@adacore.com>
1183 Javier Miranda <miranda@adacore.com>
1185 * rtsfind.ads, exp_util.adb, exp_util.ads, exp_disp.adb, exp_disp.ads,
1186 exp_ch7.adb, sem_ch9.adb, snames.adb, snames.ads,
1187 exp_ch9.adb, exp_ch9.ads, exp_ch6.adb, exp_ch3.adb, exp_ch3.ads,
1188 einfo.ads, einfo.adb: Complete support for Ada 2005 interfaces.
1190 * a-tags.ads, a-tags.adb: Major rewrite and additions to implement
1191 properly new Ada 2005 interfaces (AI-345) and add run-time checks (via
1194 * exp_dbug.ads, exp_dbug.adb (Get_Secondary_DT_External_Name): New
1195 subprogram that generates the external name associated with a
1196 secondary dispatch table.
1197 (Get_Secondary_DT_External_Name): New subprogram that generates the
1198 external name associated with a secondary dispatch table.
1200 2005-11-14 Emmanuel Briot <briot@adacore.com>
1202 * xref_lib.adb (Parse_Identifier_Info): It is possible for an entity
1203 line in the ALI file to include both an instantiation reference, and a
1206 2005-11-14 Vincent Celier <celier@adacore.com>
1208 * clean.adb (Check_Project): Look for Ada code in extending project,
1209 even if Ada is not specified as a language.
1210 Use new function DLL_Prefix for DLL_Name
1211 (Clean_Interface_Copy_Directory): New procedure
1212 (Clean_Library_Directory): New procedure
1213 (Clean_Directory): Remove procedure, no longer used
1214 (Clean_Project): Do not delete any file in an externally built project
1216 * prj-env.adb (Set_Ada_Paths.Add.Recursive_Add): Add the object
1217 directory of an extending project, even when there are no Ada source
1219 (Ada_Objects_Path.Add): Add Library_ALI_Dir, not Library_Dir to the path
1220 (Set_Ada_Paths.Add.Recursive_Add): Ditto
1222 * mlib-prj.adb (Check_Library): For all library projects, get the
1223 library file timestamp.
1224 (Build_Library): Copy ALI files in Library_ALI_Dir, not in Library_Dir
1225 (Build_Library): Use new function DLL_Prefix for the DLL_Name
1226 (Clean): Remove procedure, no longer used
1227 (Ultimate_Extension_Of): New function
1228 (Build_Library): When cleaning the library directory, only remove an
1229 existing library file and any ALI file of a source of the project.
1230 When cleaning the interface copy directory, remove any source that
1231 could be a source of the project.
1233 * prj.ads, prj.adb (Project_Empty): Add values of new components
1234 Library_TS and All_Imported_Projects.
1235 (Project_Empty): Add values for new components of Project_Data:
1236 Library_ALI_Dir and Display_Library_ALI_Dir
1238 * prj-attr.adb: New project level attribute name Library_ALI_Dir
1240 * prj-nmsc.adb (Check_Library_Attributes): Take into account new
1241 attribute Library_ALI_Dir.
1242 (Check_Library_Attributes): The library directory cannot be the same as
1243 any source directory of the project tree.
1244 (Check_Stand_Alone_Library): The interface copy directory cannot be
1245 the same as any source directory of the project tree.
1247 * mlib.adb: Use Prj.Com.Fail, instead of Osint.Fail directly, to delete
1248 all temporary files.
1250 2005-11-14 Robert Dewar <dewar@adacore.com>
1251 Ed Schonberg <schonberg@adacore.com>
1253 * sem_elab.adb: Change name Is_Package to Is_Package_Or_Generic_Package
1254 (Check_Elab_Call): A call within a protected body is never an
1255 elaboration call, and does not require checking.
1256 (Same_Elaboration_Scope): Take into account protected types for both
1258 (Activate_Elaborate_All_Desirable): New procedure
1260 * ali.ads, ali.adb: Implement new AD/ED for Elaborate_All/Elaborate
1263 * binde.adb: Implement new AD/ED for Elaborate_All/Elaborate desirable
1264 (Elab_Error_Msg): Use -da to include internal unit links, not -de.
1266 * lib-writ.ads, lib-writ.adb:
1267 Implement new AD/ED for Elaborate_All/Elaborate desirable
1268 Use new Elaborate_All_Desirable flag in N_With_Clause node
1270 * sinfo.ads, sinfo.adb (Actual_Designated_Subtype): New attribute for
1271 N_Free_Statement nodes.
1272 Define new class N_Subprogram_Instantiation
1273 Add Elaborate_Desirable flag to N_With_Clause node
1274 Add N_Delay_Statement (covering two kinds of delay)
1276 * debug.adb: Introduce d.f flag for compiler
1277 Add -da switch for binder
1279 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1280 Cyrille Comar <comar@adacore.com>
1282 * exp_aggr.adb (Build_Record_Aggr_Code): Do not create master entity
1283 for task component, in the case of a limited aggregate. The enclosed
1284 object declaration will create it earlier. Otherwise, in the case of a
1285 nested aggregate, the object may appear in the wrong scope.
1286 (Convert_Aggr_In_Object_Decl): Create a transient scope when needed.
1287 (Gen_Assign): If the component being assigned is an array type and the
1288 expression is itself an aggregate, wrap the assignment in a block to
1289 force finalization actions on the temporary created for each row of the
1291 (Build_Record_Aggr_Code): Significant rewrite insuring that ctrl
1292 structures are initialized after all discriminants are set so that
1293 they can be accessed even when their offset is dynamic.
1295 2005-11-14 Robert Dewar <dewar@adacore.com>
1296 Hristian Kirtchev <kirtchev@adacore.com>
1298 * sem_attr.adb: Implement Machine_Rounding attribute
1299 (Analyze_Access_Attribute): The access attribute may appear within an
1300 aggregate that has been expanded into a loop.
1301 (Check_Task_Prefix): Add semantic check for attribute 'Callable and
1302 'Terminated whenever the prefix is of a task interface class-wide type.
1303 (Analyze_Attribute): Add semantic check for attribute 'Identity whenever
1304 the prefix is of a task interface class-wide type.
1306 * s-vaflop-vms-alpha.adb: Valid_D, Valid_F, Valid_G: Make Val constant
1309 * s-fatgen.ads, s-fatgen.adb (Machine_Rounding): New function
1310 Remove pragma Inline for [Unaligned_]Valid.
1311 Add comments that Valid routines do not work for Vax_Float
1313 * exp_attr.adb: Implement Machine_Rounding attribute
1315 * snames.h: Add entry for Machine_Rounding attribute
1317 2005-11-14 Javier Miranda <miranda@adacore.com>
1318 Robert Dewar <dewar@adacore.com>
1319 Hristian Kirtchev <kirtchev@adacore.com>
1321 * exp_attr.adb (Expand_N_Attribute_Reference, cases of Attribute_Size
1322 and related): For a prefix that is an explicit dereference of an
1323 access to unconstrained packed array type, annotate the dereference
1324 with an actual subtype so GIGI can make a correct size computation.
1325 (Expand_N_Attribute_Reference): In case of 'Unchecked_Access and
1326 'Unrestricted_Access, if the designated type is an interface we
1327 add a type conversion to force the displacement of the pointer
1328 to the secondary dispatch table.
1329 Use Universal_Real instead of Long_Long_Float when we need a high
1330 precision float type for the generated code (prevents gratuitous
1331 Vax_Float stuff when pragma Float_Representation (Vax_Float) used)
1332 (Expand_N_Attribute_Reference): Add support for attribute 'Callable and
1333 'Terminated for task interface class-wide objects. Generate a call to
1334 the predefined dispatching routine used to retrieve the _task_id from
1335 a task corresponding record.
1336 (Expand_Fpt_Attribute): Major change to properly handle Vax_Float
1338 * sem_disp.adb: Change name Is_Package to Is_Package_Or_Generic_Package
1339 (Check_Dispatching_Operation): Protect the frontend againts
1340 previously detected errors.
1342 * Makefile.rtl: Add new instantiations of system.fat_gen
1344 * s-fatflt.ads, s-fatlfl.ads, s-fatllf.ads, s-fatsfl.ads:
1345 Change name of instantiated package for better consistency
1346 with newly added system.fat_gen instantiations.
1348 * s-filofl.ads, s-fishfl.ads, s-fvadfl.ads, s-fvaffl.ads,
1349 s-fvagfl.ads: New files.
1351 2005-11-14 Cyrille Comar <comar@adacore.com>
1352 Thomas Quinot <quinot@adacore.com>
1354 * exp_ch5.adb (Expand_N_Assignment_Statement, Tagged_Case): For an
1355 assignment of a value of a tagged type that has been rewritten to a
1356 block statement, it is known by construction that no checks are
1357 necessary for the statements within the block: analyze it with checks
1359 (Expand_N_If_Statement): When killing a dead then-branch in an
1360 if-statement that has elsif_parts, recompute the Current_Value node
1361 for any entity whose value is known from the condition of the first
1363 (Expand_N_Return_Statement): When returning a mutable record, convert
1364 the return value into its actual subtype in order to help the backend
1365 to return the actual size instead of the maximum. This is another
1366 aftermath of not returning mutable records on the sec-stack anymore.
1368 * sem_ch5.ads, sem_ch5.adb (Analyze_Iteration_Scheme): Minor change to
1369 handling of error msg for suspicious reverse range iteration.
1370 (Check_Possible_Current_Value_Condition): Move declaration from body to
1371 spec, to allow this subprogram to be called from exp_ch5.
1373 2005-11-14 Thomas Quinot <quinot@adacore.com>
1375 * exp_dist.adb (Append_Array_Traversal): Modify constrained case to
1376 generate a set of nested array aggregates instead of a single flat
1377 aggregate for multi-dimensional arrays.
1379 2005-11-14 Pascal Obry <obry@adacore.com>
1381 * expect.c (__gnat_kill) [Win32]: Fix implementation, the pid returned
1382 by spawnve is a process handle, no need to convert. Add a parameter
1383 close to control wether the process handle must be closed.
1384 (__gnat_waitpid): Fix implementation, the pid returned by spawnve is
1385 a process handle, not need to convert.
1386 (__gnat_kill) [*]: Add dummy parameter close to match the Win32 spec.
1388 * g-expect.adb: (Kill): Document the new close parameter.
1389 (Close): Do not release the process handle in the kill there as
1390 waitpid() is using it.
1391 (Send_Signal): Release the process handle.
1393 2005-11-14 Robert Dewar <dewar@adacore.com>
1395 * exp_fixd.adb: Use Universal_Real instead of Long_Long_Float when we
1396 need a high precision float type for the generated code (prevents
1397 gratuitous Vax_Float stuff when pragma Float_Representation (Vax_Float)
1400 * exp_imgv.adb: Use Universal_Real instead of Long_Long_Float when we
1401 need a high precision float type for the generated code (prevents
1402 gratuitous Vax_Float stuff when pragma Float_Representation (Vax_Float)
1404 (Expand_Width_Attribute): In configurable run-time, the attribute is not
1405 allowed on non-static enumeration subtypes. Force a load error to emit
1406 the correct diagnostic.
1408 2005-11-14 Thomas Quinot <quinot@adacore.com>
1409 Robert Dewar <dewar@adacore.com>
1410 Ed Schonberg <schonberg@adacore.com>
1412 * exp_intr.adb (Expand_Unc_Deallocation): If GIGI needs an actual
1413 subtype to compute the size of the designated object at run-time,
1414 create such a subtype and store it in the Actual_Designated_Subtype
1415 attribute of the N_Free_Statement.
1416 Generate itype for classwide designated object in both cases of
1417 user-specified storage pool: specific and class-wide, not only in the
1419 Raise CE when trying to set a not null access type object to null.
1420 (Expand_Dispatching_Constructor_Call): Retrieve subprogram actual with
1421 an explicit loop, because freeze nodes make its position variable.
1423 * sem_intr.adb (Check_Intrinsic_Call): Given warning for freeing not
1426 2005-11-14 Javier Miranda <miranda@adacore.com>
1428 * exp_strm.adb (Build_Stream_Attr_Profile, Build_Stream_Function,
1429 Build_Stream_Procedure): Add the null-excluding attribute to the first
1431 This has no semantic meaning under Ada95 mode but it is a
1432 requirement under Ada05 mode.
1434 * par-ch3.adb (P_Access_Definition): Addition of warning message if
1435 the null exclusion is used under Ada95 mode
1436 (P_Null_Exclusion): The qualifier has no semantic meaning in Ada 95.
1437 (P_Access_Definition): Remove assertion that forbids the use of
1438 the null-exclusion feature in Ada95.
1440 2005-11-14 Robert Dewar <dewar@adacore.com>
1442 * impunit.adb: Exclude container helper units not intended for use by
1445 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1447 * freeze.adb (Freeze_Entity): For an access formal that is an access
1448 to subprogram, freeze the anonymous subprogram type at the same time,
1449 to prevent later freezing in the wrong scope, such as the enclosing
1451 (Freeze_Entity): Freeze the equivalent_type of an access_to_protected_
1452 subprogram whenever available.
1454 2005-11-14 Arnaud Charlet <charlet@adacore.com>
1457 * gnatvsn.ads (Library_Version): Bump to 4.1
1459 2005-11-14 Robert Dewar <dewar@adacore.com>
1461 * g-debpoo.adb (Set_Valid): Use Integer_Address instead of
1462 Storage_Offset to avoid wrap around causing invalid results.
1464 2005-11-14 Pascal Obry <obry@adacore.com>
1466 * gnatbind.adb (Is_Cross_Compiler): New function returning True for
1468 (Scan_Bind_Arg): Fail with an error message if -M option is used
1469 on a native compiler.
1471 2005-11-14 Robert Dewar <dewar@adacore.com>
1472 Vincent Celier <celier@adacore.com>
1474 * gprep.adb: Implement -C switch to scan comments
1476 * scng.adb: Scan comment symbol separately if Replace_In_Comments set
1478 * scans.ads: Comment updates (including new use of Tok_Comment in
1481 * opt.ads: Add documentation for flags that are used by gprmake,
1482 currently and in the next version of gprmake.
1483 (Verbosity_Level): New variable
1484 Add Replace_In_Comments switch
1486 * vms_data.ads: Add VMS equivalent for new gnatmake switches -vl, -vm
1488 Add /REPLACE_IN_COMMENTS for gnatprep -C switch
1490 2005-11-14 Arnaud Charlet <charlet@adacore.com>
1492 * g-regpat.adb (Fail): raise Expression_Error including the diagnostic
1493 message, friendlier.
1495 2005-11-14 Robert Dewar <dewar@adacore.com>
1497 * g-spitbo.adb: (Hash): Rotate by 3 instead of 1
1499 2005-11-14 Doug Rupp <rupp@adacore.com>
1501 * init.c [VMS]: Don't install __gnat_error_handler if DBG$TDBG defined.
1503 2005-11-14 Robert Dewar <dewar@adacore.com>
1505 * interfac.ads: Change declarations of IEEE float types so that we no
1506 longer need a separate version of this package for VMS.
1508 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1510 * lib-xref.adb (Generate_Definition, Generate_Reference): Treat the
1511 internal entity created for the declaration of a child subprogram body
1512 with no spec as coming from source, to generate proper cross-reference
1515 2005-11-14 Vincent Celier <celier@adacore.com>
1517 * make.adb (Compile_Sources): Change verbose message to minimum
1518 verbosity level High for "is in an Ada library", "is a read-only
1519 library" and "is an internal library",
1520 (Create_Binder_Mapping_File): Path name of ALI file for library project
1521 must include the library directory, not the object directory.
1522 (Scan_Make_Arg): Make sure that Switch.M.Scan_Make_Switches is called
1523 for new switches -vl, -vm and -vh.
1524 (Verbose_Msg): Add new defaulted parameter Minimum_Verbosity
1525 (Check): Use minimum verbosity Medium for some Verbose_Msg calls
1526 (Compile_Sources): Do not attempt to compile if an ALI file is missing
1527 in a project that is externally built.
1528 (Compute_All_Imported_Projects): New procedure
1529 (Gnatmake): Check if importing libraries should be regenerated because
1530 at least an imported library is more recent.
1531 (Initialize): For each project compute the list of the projects it
1532 imports directly or indirectly.
1533 (Add_Library_Search_Dir): New procedure, used in place of
1534 Add_Lib_Search_Dir in procedure Scan_Make_Arg so that absolute paths are
1535 put in the search paths.
1536 (Add_Source_Search_Dir): New procedure, used in place of
1537 Add_Src_Search_Dir in procedure Scan_Make_Arg so that absolute paths are
1538 put in the search paths.
1539 (Mark_Directory): Resolve the absolute path the directory before marking
1542 * switch-m.adb (Scan_Make_Switches): Replace "raise Bad_Switch;" with
1543 call to new procedure Bad_Switch. Call Scan_Pos with new parameter
1544 Switch. Do not handle any exception.
1545 (Scan_Make_Switches): Increment Ptr for new switches -vl, -vm and -vh
1546 so that the switch is recognized as valid.
1547 (Scan_Make_Switches): Implement new switches -vl, -vm and -vh.
1549 2005-11-14 GNAT Script <nobody@adacore.com>
1551 * Make-lang.in: Makefile automatically updated
1553 2005-11-14 Pascal Obry <obry@adacore.com>
1555 * mdll.adb (Build_Reloc_DLL): Fix parameter handling when a map file is
1557 (Ada_Build_Reloc_DLL): Fix parameter handling when a map file is used.
1558 In both cases the last argument was dropped.
1560 2005-11-14 Eric Botcazou <ebotcazou@adacore.com>
1562 * namet.h: (Column_Numbe): New type.
1563 (Get_Column_Number): Define to sinput__get_column_number.
1564 (Instantiation): Define to sinput__instantiation.
1565 (Get_Column_Number): Declare.
1566 (Instantiation): Likewise.
1568 2005-11-14 Robert Dewar <dewar@adacore.com>
1570 * par-ch10.adb (P_Compilation_Unit): Add defenses against junk unit
1571 syntax, which could cause compiler hangs.
1573 2005-11-14 Vincent Celier <celier@adacore.com>
1575 * prj-ext.adb: Take into account new environment variable
1576 GPR_PROJECT_PATH. Warn if both GPR_PROJECT_PATH and ADA_PROJECT_PATH
1578 (Prj.Ext elaboration): For each directory in the ADA_PROJECT_PATH,
1579 normalize its path name, making it absolute and resolving symbolic
1580 links, and replace the original if resolved path is different.
1582 2005-11-14 Vincent Celier <celier@adacore.com>
1584 * prj-part.adb (Create_Virtual_Extending_Project): Put virtual project
1585 into Prj.Tree.Tree_Private_Part.Projects_Htable for GPS.
1587 2005-11-14 Emmanuel Briot <briot@adacore.com>
1589 * prj-pp.adb (Print): Do not output the with statement if the
1590 associated name is empty, which happens for virtual extending projects.
1591 (Print): Preserve the "extends all" attribute when printing the project.
1593 * prj-tree.ads (String_Value_Of): Add comment about returned value for
1594 a virtual extending project.
1596 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1598 * sem_aggr.adb (Resolve_Aggregate): An others choice is legal on the
1599 rhs of an assignment even if the type is unconstrained, when the
1600 context is non-expanding.
1601 In an inlined body, if the context type is private,
1602 resolve with its full view, which must be a composite type.
1604 2005-11-14 Robert Dewar <dewar@adacore.com>
1605 Ed Schonberg <schonberg@adacore.com>
1607 * sem_ch10.adb: Change name Is_Package to Is_Package_Or_Generic_Package
1608 Do not give obsolescent warning on with of subprogram (since we
1610 (Analyze_With_Clause): Add test for obsolescent package
1611 (Install_Context_Clauses): If the unit is the body of a child unit, do
1612 not install twice the private declarations of the parents, to prevent
1613 circular lists of Use_Clauses in a parent.
1614 (Implicit_With_On_Parent): Do add duplicate with_clause on parent when
1615 compiling body of child unit.
1616 Use new class N_Subprogram_Instantiation
1617 (Expand_With_Clause): If this is a private with_clause for a child unit,
1618 appearing in the context of a package declaration, then the implicit
1619 with_clauses generated for parent units are private as well.
1620 (License_Check): Do not generate message if with'ed unit is internal
1622 2005-11-14 Gary Dismukes <dismukes@adacore.com>
1623 Ed Schonberg <schonberg@adacore.com>
1624 Thomas Quinot <quinot@adacore.com>
1626 * sem_ch12.ads, sem_ch12.adb (Map_Entities): Exclude entities whose
1627 names are internal, because they will not have a corresponding partner
1628 in the actual package.
1629 (Analyze_Formal_Package): Move the setting of the formal package spec's
1630 Generic_Parent field so that it occurs prior to analyzing the package,
1631 to allow proper operation of Install_Parent_Private_Declarations.
1632 (Analyze_Package_Instantiation): Set the instantiated package entity's
1633 Package_Instantiation field.
1634 (Get_Package_Instantiation_Node): Move declaration to package spec.
1635 Retrieve the N_Package_Instantiation node when the Package_Instantiation
1637 (Check_Generic_Child_Unit): Within an inlined call, the only possible
1638 instantiation is Unchecked_Conversion, for which no parents are needed.
1639 (Inline_Instance_Body): Deinstall and record the use_clauses for all
1640 parent scopes of a scope being removed prior to inlining an instance
1642 (Analyze_Package_Instantiation): Do not perform front-end inlining when
1643 the current context is itself an instance within a non-instance child
1644 unit, to prevent scope stack errors.
1645 (Save_References): If the node is an aggregate that is an actual in a
1646 call, rewrite as a qualified expression to preserve some type
1647 information, to resolve possible ambiguities in the instance.
1648 (Instance_Parent_Unit): New global variable to record the ultimate
1649 parent unit associated with a generic child unit instance (associated
1650 with the existing Parent_Unit_Visible flag).
1651 (type Instance_Env): New component Instance_Parent_Unit for stacking
1652 parents recorded in the global Instance_Parent_Unit.
1653 (Init_Env): Save value of Instance_Parent_Unit in the Instance_Env
1655 (Install_Spec): Save the parent unit entity in Instance_Parent_Unit when
1656 it's not a top-level unit, and only do this if Instance_Parent_Unit is
1657 not already set. Replace test of Is_Child_Unit with test of parent's
1658 scope against package Standard. Add comments and a ??? comment.
1659 (Remove_Parent): Revise condition for resetting Is_Immediately_Visible
1660 on a child instance parent to test that the parent equals
1661 Instance_Parent rather than simply checking that the unit is not a
1663 (Restore_Env): Restore value of Instance_Parent_Unit from Instance_Env.
1664 (Validate_Derived_Interface_Type_Instance): Verify that all ancestors of
1665 a formal interface are ancestors of the corresponding actual.
1666 (Validate_Formal_Interface_Type): Additional legality checks.
1667 (Analyze_Formal_Derived_Interface_Type): New procedure to handle formal
1668 interface types with ancestors.
1669 (Analyze_Formal_Package): If formal is a renaming, use renamed entity
1670 to diagnose attempts to use generic within its own declaration.
1672 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1673 Javier Miranda <miranda@adacore.com>
1675 * sem_ch3.ads, sem_ch3.adb (Build_Discriminal): Add link to original
1677 (Build_Private_Derived_Type): The entity of the created full view of the
1678 derived type does not come from source. If after installing the private
1679 declarations of the parent scope the parent is still private, use its
1680 full view to construct the full declaration of the derived type.
1681 (Build_Derived_Record_Type): Relax the condition that controls the
1682 execution of the check that verifies that the partial view and
1683 the full view agree in the set of implemented interfaces. In
1684 addition, this test now only takes into account the progenitors.
1685 (Derive_Interface_Subprograms): No need to derive subprograms
1686 of ancestors that are interfaces.
1687 (Derive_Subprograms): Remove formal No_Predefined_Prims and the
1689 Change name Is_Package to Is_Package_Or_Generic_Package
1690 (Complete_Subprograms_Derivation): Handle the case in which the full
1691 view is a transitive derivation of the ancestor of the partial view.
1692 (Process_Full_View): Rename local subprogram Find_Interface_In_
1693 Descendant to Find_Ancestor_Interface to leave the code more clear.
1694 Remove wrong code that avoids the generation of an error message
1695 when the immediate ancestor of the partial view is an interface.
1696 In addition some minor reorganization of the code has been done to
1697 leave it more clear.
1698 (Analyze_Type_Declaration): If type has previous incomplete tagged
1699 partial view, inherit properly its primitive operations.
1700 (Collect_Interfaces): Make public, for analysis of formal
1702 (Analyze_Interface_Declaration): New procedure for use for regular and
1703 formal interface declarations.
1704 (Build_Derived_Record_Type): Add support for private types to the code
1705 that checks if a tagged type implements abstract interfaces.
1706 (Check_Aliased_Component_Type): The test applies in the spec of an
1708 (Access_Type_Declaration): Clean up declaration of malformed type
1709 declared as an access to its own classwide type, to prevent cascaded
1711 (Collect_Interfaces): For private extensions and for derived task types
1712 and derived protected types, the parent may be an interface that must
1713 be included in the interface list.
1714 (Access_Definition): If the designated type is an interface that may
1715 contain tasks, create Master_Id for it before analyzing the expression
1716 of the declaration, which may be an allocator.
1717 (Record_Type_Declaration): Set properly the interface kind, for use
1718 in allocators, the creation of master id's for task interfaces, etc.
1720 2005-11-14 Javier Miranda <miranda@adacore.com>
1721 Ed Schonberg <schonberg@adacore.com>
1723 * sem_ch6.adb (Check_Conformance): The null-exclusion feature can be
1724 omitted in case of stream attribute subprograms.
1725 (Check_Inline_Pragma): Handle Inline and Inline_Always pragmas that
1726 appear immediately after a subprogram body, when there is no previous
1727 subprogram declaration.
1728 Change name Is_Package to Is_Package_Or_Generic_Package
1729 (Process_Formals): A non null qualifier on a non null named access
1730 type is not an error, and is a warning only if Redundant_Constructs
1733 2005-11-14 Gary Dismukes <dismukes@adacore.com>
1734 Ed Schonberg <schonberg@adacore.com>
1736 * sem_ch7.adb (Install_Parent_Private_Declarations): New procedure
1737 nested within Analyze_Package_Specification to install the private
1738 declarations and use clauses within each of the parent units of a
1739 package instance of a generic child package.
1740 (Analyze_Package_Specification): When entering a private part of a
1741 package associated with a generic instance or formal package, the
1742 private declarations of the parent must be installed (by calling new
1743 procedure Install_Parent_Private_Declarations).
1744 Change name Is_Package to Is_Package_Or_Generic_Package
1745 (Preserve_Full_Attributes): For a synchronized type, the corresponding
1746 record is absent in a generic context, which does not indicate a
1749 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1751 * sem_ch8.adb (Analyze_Subprogram_Renaming): In a generic context, do
1752 not try to rewrite a renamed stream attribute, because the operations
1753 on the type may not have been generated.
1754 Handle properly a renaming_as_body generated for a stream operation
1755 whose default is abstract because the object type itself is abstract.
1756 (Find_Type): If the type is incomplete and appears as the prefix of a
1757 'Class reference, it is tagged, and its list of primitive operations
1758 must be initialized properly.
1759 (Chain_Use_Clauses): When chaining the use clauses that appear in the
1760 private declaration of a parent unit, prior to compiling the private
1761 part of a child unit, find on the scope stack the proper parent entity
1762 on which to link the use clause.
1763 (Note_Redundant_Use): Emit a warning when a redundant use clause is
1765 (Analyze_Object_Renaming): An attribute reference is not a legal object
1766 if it is not a function call.
1768 2005-11-14 Robert Dewar <dewar@adacore.com>
1769 Ed Schonberg <schonberg@adacore.com>
1771 * sem_eval.adb: Implement d.f flag
1772 (Subtype_Statically_Match): A generic actual type has unknown
1773 discriminants when the corresponding actual has a similar partial view.
1774 If the routine is called to validate the signature of an inherited
1775 operation in a child instance, the generic actual matches the full view,
1777 2005-11-14 Hristian Kirtchev <kirtchev@adacore.com>
1778 Ed Schonberg <schonberg@adacore.com>
1779 Robert Dewar <dewar@adacore.com>
1780 Thomas Quinot <quinot@adacore.com>
1782 * sem_res.adb (Resolve_Call): Provide a better error message whenever
1783 a procedure call is used as a select statement trigger and is not an
1784 entry renaming or a primitive of a limited interface.
1785 (Valid_Conversion): If the operand has a single interpretation do not
1786 remove address operations.
1787 (Check_Infinite_Recursion): Skip freeze nodes when looking for a raise
1788 statement to inhibit warning.
1789 (Resolve_Unary_Op): Do not produce a warning when
1790 processing an expression of the form -(A mod B)
1791 Use Universal_Real instead of Long_Long_Float when we need a high
1792 precision float type for the generated code (prevents gratuitous
1793 Vax_Float stuff when pragma Float_Representation (Vax_Float) used)
1794 (Resolve_Concatenation_Arg): Improve error message when argument is an
1795 ambiguous call to a function that returns an array.
1796 (Make_Call_Into_Operator, Operand_Type_In_Scope): Do not check that
1797 there is an implicit operator in the given scope if we are within an
1798 instance: legality check has been performed on the generic.
1799 (Resolve_Unary_Op): Apply warnings checks on argument of Abs operator
1800 after resolving operand, to avoid false warnings on overloaded calls.
1802 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1803 Javier Miranda <miranda@adacore.com>
1807 * sem_type.adb (Covers): In an inlined body, a composite type matches
1808 a private type whose full view is a composite type.
1809 (Interface_Present_In_Ancestor): Protect the frontend against
1810 previously detected errors to ensure that its compilation
1811 with assertions enabled gives the same output that its
1812 compilation without assertions.
1813 (Interface_Present_In_Ancestor): Add support for private types.
1814 Change name In_Actual to In_Generic_Actual (clean up)
1815 (Disambiguate): New predicate In_Actual, to recognize expressions that
1816 appear in the renaming declaration generated for generic actuals, and
1817 which must be resolved in the outer context.
1819 2005-11-14 Robert Dewar <dewar@adacore.com>
1820 Thomas Quinot <quinot@adacore.com>
1821 Hristian Kirtchev <kirtchev@adacore.com>
1822 Ed Schonberg <schonberg@adacore.com>
1824 * sem_util.ads, sem_util.adb: Change name Is_Package to
1825 Is_Package_Or_Generic_Package.
1826 (Check_Obsolescent): New procedure.
1827 (Set_Is_Public): Remove obsolete junk test.
1828 (Set_Public_Status): Do not set Is_Public on an object whose declaration
1829 occurs within a handled_sequence_of_statemets.
1830 (Is_Controlling_Limited_Procedure): Factor some of the logic, account
1831 for a parameterless procedure.
1832 (Enter_Name): Recognize renaming declarations created for private
1833 component of a protected type within protected operations, so that
1834 the source name of the component can be used in the debugger.
1836 2005-11-14 Ed Schonberg <schonberg@adacore.com>
1837 Robert Dewar <dewar@adacore.com>
1839 * sem_warn.ads, sem_warn.adb (Publicly_Referenceable): Generic formals
1840 of a generic subprogram are not visible outside the body.
1841 (Set_Warning_Switch): New procedure (code to set warning mode moved
1842 here from Switch.C so that it can be shared by pragma processing.
1843 (Check_References): Special case warning for non-modified non-imported
1845 * par-prag.adb: Modify processing of pragma Warnings to accomodate new
1846 form with a string literal argument
1848 2005-11-14 Javier Miranda <miranda@adacore.com>
1850 * s-finroo.ads, s-finroo.adb (Read): Addition of "not null" to the
1852 (Write): Addition of "not null" to the anonymous access.
1853 (Read): Addition of "not null" to the anonymous access.
1854 (Write): Addition of "not null" to the anonymous access.
1856 * s-strxdr.adb, s-stratt.ads, s-stratt.adb (I_AD, I_AS, I_B, I_C, I_F,
1857 I_I, I_LF, I_LI, I_LLF, I_LLI, I_LLU, I_LU, I_SF, I_SI, I_SSI, I_SSU,
1858 I_SU, I_U, I_WC): Addition of "not null" to the anonymous access.
1859 (W_AD, W_AS, W_B, W_C, W_F, W_I, W_LF, W_LI, W_LLF, W_LLI, W_LLU,
1860 W_LU, W_SF, W_SI, W_SSI, W_SSU, W_SU, W_U, W_WC): Addition of
1861 "not null" to the anonymous access.
1863 2005-11-14 Robert Dewar <dewar@adacore.com>
1865 * s-stoele.adb: Fix code for Address mod Storage_Offset for negative
1868 2005-11-14 Vincent Celier <celier@adacore.com>
1870 * switch.adb (Bad_Switch): New procedure
1871 (Scan_Nat, Scan_Pos): Directly call Osint.Fail with the appropriate
1872 message when in error.
1874 * switch.ads (Bad_Switch, Bad_Switch_Value, Missing_Switch_Value,
1875 Too_Many_Output_Files): Remove declarations, no longer used.
1876 (Scan_Nat): New parameter Switch
1878 (Bad_Switch): New procedure
1880 * switch-b.adb (Scan_Binder_Switches): Replace "raise Bad_Switch;"
1881 with call to new procedure Bad_Switch. Call Scan_Pos and Scan_Natwith
1882 new parameter Switch. Replace "raise Too_Many_Output_Files;" with call
1883 to Osint.Fail. Do not handle any exception.
1885 2005-11-14 Vincent Celier <celier@adacore.com>
1887 * tempdir.adb (Tempdir): Do not use environment variable TMPDIR if it
1888 designates a non existent directory.
1890 2005-11-14 Robert Dewar <dewar@adacore.com>
1892 * xgnatugn.adb: Replace invalid membership test by 'Valid
1894 2005-11-14 Vincent Celier <celier@adacore.com>
1896 * makegpr.adb (Gprmake): Do not attempt to build the global archive if
1897 there is no object directory.
1899 2005-11-14 Robert Dewar <dewar@adacore.com>
1901 * usage.adb: Minor adjustment to output format, use nn instead of nnn
1902 (so that -gnateInnn does not run into next column)
1904 2005-11-14 Ed Falis <falis@adacore.com>
1906 * s-bitops.adb (Bits_Array): corrected comment: "unconstrained" =>
1909 2005-11-14 Cyrille Comar <comar@adacore.com>
1911 * s-chepoo.ads: Add comments on Dereference.
1912 Remove unnecessary inherited abstract primitives.
1915 2005-11-14 Robert Dewar <dewar@adacore.com>
1917 * sem_cat.ads (Validate_Access_Type_Declaration): Remove declaration
1918 node parameter, not needed, since it is available as Declaration_Node.
1920 2005-11-14 Geert Bosch <bosch@adacore.com>
1922 * s-exnllf.adb (Exn_LLF): Fix comment to be more precise and
1923 grammatically correct.
1925 2005-11-14 Vincent Celier <celier@adacore.com>
1927 * s-fileio.ads: Correct spelling error in comment
1929 2005-11-14 Cyrille Comar <comar@adacore.com>
1930 Robert Dewar <dewar@adacore.com>
1931 Vincent Celier <celier@adacore.com>
1932 Ben Brosgol <brosgol@adacore.com>
1933 Jose Ruiz <ruiz@adacore.com>
1934 Pascal Obry <obry@adacore.com>
1937 Document that -fstack-check is needed for strict compliance with the
1938 Ada 95 Reference Manual.
1939 Correct reference to VAX systems to meet HP guidelines
1940 Add documentation for new gnatmake switches -vl, -vm and -vh
1941 Replace DEC Ada by HP Ada
1942 Replace DIGITAL by HP
1943 Remove empty section on tools in compatibility section
1944 Clarify the Windows convention semantics.
1945 Document the Win32 calling convention.
1946 The Stdcall, Win32 and DLL convention are synonyms.
1947 Add a note in -gnatR description about zero size record components
1948 Note on new >= and <= warnings for -gnatwc
1949 Document that equal sign after -gnatm is optional.
1950 Note that strip is working fine on DLL built with a Library
1951 Project. The restriction apply only to DLL built with gnatdll.
1952 Update section about the way to debug a DLL.
1953 Update information about the DLL convention.
1954 Document -C switch for gnatprep
1955 Document new attribute Library_ALI_Dir
1956 Update elaboration doc to include implicit Elaborate pragmas now
1957 generated for subprogram instantiations.
1958 Document limitation on executable names that include spaces for --GCC,
1959 --GNATBIND, and --GNATLINK switches.
1960 Document that -w causes -gnatws to be added at start of gcc switches
1962 * gnat_rm.texi: Document that -mieee is needed for generating infinite
1963 and NaN values in case of overflow on machines that are not fully
1964 compliant with the IEEE floating-point standard.
1965 Create a section describing the set of compiler options needed for
1966 strict compliance with the Ada 95 Reference Manual.
1967 Add documentation for pragma Obsolescent applied to a package
1968 Clarify potential issues of mixed language programs related to the
1969 I/O buffering enabling in the elaboration of the GNAT runtime.
1970 Add extra documentation for pragma Restrictions (No_Elaboration_Code)
1971 This documentation only patch adds extra documentsion for pragma
1972 Restrictions (No_Elaboration_Code), explaining why it is not possible
1973 to document this restriction in terms of allowed source constructs.
1974 Document string literal form of pragma Warnings
1975 Document new attribute Library_ALI_Dir
1976 Add documentation on stable attributes in project files that was missing
1978 * gnat-style.texi: Indicate that paragraphs within a single comment
1979 should be separated by empty comment lines
1981 * ug_words: Added replacements for -gnat95 and -gnat05 (/95 and
1984 * bindusg.adb: Minor cleanup, put -m before -M for consistency
1986 2005-11-14 Robert Dewar <dewar@adacore.com>
1988 * a-secain.adb, a-slcain.adb, a-shcain.adb, a-chtgke.ads, a-chtgke.adb,
1989 a-stwiha.adb, a-strhas.adb, a-chzla1.ads, a-chzla9.ads, a-stzbou.adb,
1990 a-stzbou.ads, a-stzfix.adb, a-stzhas.adb, a-stzmap.adb, a-stzmap.ads,
1991 a-stzsea.adb, a-stzsea.ads, a-stzsup.adb, a-stzsup.ads, a-stzunb.adb,
1992 a-stzunb.ads, a-szuzha.adb, a-szuzha.ads, a-szuzti.adb, a-szuzti.ads,
1993 a-ztcoau.adb, a-ztcoau.ads, a-ztcoio.adb, a-ztcstr.adb, a-ztcstr.ads,
1994 a-ztdeau.adb, a-ztdeau.ads, a-ztdeio.adb, a-ztdeio.ads, a-ztedit.adb,
1995 a-ztedit.ads, a-ztenau.ads, a-ztenio.adb, a-ztenio.ads, a-ztexio.adb,
1996 a-ztexio.ads, a-ztfiio.adb, a-ztfiio.ads, a-ztflau.adb, a-ztflau.ads,
1997 a-ztflio.adb, a-ztflio.ads, a-ztgeau.adb, a-ztgeau.ads, a-ztinau.adb,
1998 a-ztinau.ads, a-ztinio.adb, a-ztmoau.ads, a-ztmoio.adb, a-ztmoio.ads,
1999 a-zttest.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-alpha.adb,
2000 g-enblsp-vms-ia64.adb, g-enblsp-vms-ia64.adb, system-linux-hppa.ads,
2001 a-chacon.adb, a-chacon.ads, a-wichun.adb, a-wichun.ads, a-zchuni.adb,
2002 a-zchuni.ads, g-trasym-vms-alpha.adb, g-trasym-vms-ia64.adb,
2003 system-hpux-ia64.ads, g-soccon-unixware.ads, g-soliop-unixware.ads,
2004 g-soccon-interix.ads, g-soliop-solaris.ads, g-eacodu-vms.adb,
2005 g-expect-vms.adb, g-socthi-vms.adb, g-soliop-mingw.ads,
2006 a-intnam-unixware.ads, a-intnam-lynxos.ads, a-intnam-tru64.ads,
2007 a-intnam-aix.ads, a-intnam-linux.ads, a-intnam-linux.ads,
2008 a-intnam-dummy.ads, a-numaux-libc-x86.ads, a-intnam-interix.ads,
2009 a-intnam-solaris.ads, a-calend-vms.adb, a-calend-vms.ads,
2010 a-intnam-vms.ads, a-calend-mingw.adb, a-intnam-mingw.ads,
2011 a-intnam-vxworks.ads, a-numaux-vxworks.ads, system-unixware.ads,
2012 system-linux-ia64.ads, a-intnam-freebsd.ads, system-freebsd-x86.ads,
2013 system-lynxos-ppc.ads, system-linux-x86_64.ads, a-stunha.adb,
2014 a-cgaaso.ads, a-cgaaso.adb, a-chtgop.adb, a-cgcaso.adb, a-cgarso.adb,
2015 a-cohata.ads, a-crbtgk.adb, a-crbltr.ads, a-coprnu.adb, a-rbtgso.adb,
2016 a-intnam-darwin.ads, system-darwin-ppc.ads, gprmake.adb, makegpr.ads,
2017 system-tru64.ads, system-aix.ads, system-solaris-x86.ads,
2018 system-irix-o32.ads, s-interr-sigaction.adb, system-irix-n32.ads,
2019 s-parame-mingw.adb, system-hpux.ads, s-traceb-hpux.adb,
2020 system-linux-x86.ads, s-inmaop-dummy.adb, system-os2.ads,
2021 system-interix.ads, system-solaris-sparc.ads,
2022 system-solaris-sparcv9.ads, s-inmaop-vms.adb,
2023 s-mastop-vms.adb, expander.adb, expander.ads, s-gloloc-mingw.adb,
2024 system-mingw.ads, system-vms-zcx.ads, s-osinte-fsu.adb,
2025 s-traceb-mastop.adb, a-exextr.adb, a-exstat.adb, a-filico.ads,
2026 a-finali.ads, a-interr.ads, a-intsig.adb, a-intsig.ads,
2027 a-except.ads, a-numaux-x86.ads, a-astaco.adb, a-calend.adb,
2028 a-calend.ads, a-chahan.adb, a-chahan.ads, a-chlat9.ads,
2029 a-colien.adb, a-colien.ads, a-colire.adb, a-colire.ads,
2030 a-comlin.adb, a-comlin.ads, a-cwila1.ads, a-cwila9.ads,
2031 a-elchha.adb, a-decima.adb, a-decima.ads, a-diocst.ads,
2032 a-direio.adb, a-direio.ads, a-excach.adb, a-excach.adb,
2033 a-exctra.ads, ali-util.adb, a-ngcefu.adb, a-ngcoty.adb,
2034 a-ngcoty.ads, a-nudira.adb, a-nudira.ads, a-nuflra.adb,
2035 a-numaux.ads, a-reatim.ads, a-sequio.adb, a-sequio.ads,
2036 a-siocst.ads, a-ssicst.ads, a-stmaco.ads, a-storio.adb,
2037 a-strbou.adb, a-strbou.ads, a-stream.ads, a-strfix.adb,
2038 a-strmap.adb, a-strmap.ads, a-strsea.adb, a-strsea.ads,
2039 a-strsup.adb, a-strsup.ads, a-strunb.adb, a-strunb.ads,
2040 a-stwibo.adb, a-stwibo.ads, a-stwifi.adb, a-stwima.adb,
2041 a-stwima.ads, a-stwise.adb, a-stwise.ads, a-stwisu.adb,
2042 a-stwisu.ads, a-stwiun.adb, a-stwiun.ads, a-suteio.adb,
2043 a-suteio.ads, a-swmwco.ads, a-swuwti.adb, a-swuwti.ads,
2044 a-sytaco.adb, a-sytaco.ads, a-tasatt.adb, a-taside.adb,
2045 a-taside.ads, a-teioed.adb, a-textio.adb, a-textio.ads,
2046 a-ticoau.adb, a-ticoau.ads, a-ticoio.adb, a-tideau.adb,
2047 a-tideio.adb, a-tienau.adb, a-tienio.adb, a-tifiio.adb,
2048 a-tiflio.adb, a-tigeau.adb, a-tigeau.ads, a-tiinau.adb,
2049 a-tiinio.adb, a-timoau.adb, a-timoio.adb, a-timoio.ads,
2050 a-tiocst.ads, a-titest.adb, atree.adb, a-witeio.adb,
2051 a-witeio.ads, a-wtcoau.adb, a-wtcoau.ads, a-wtcoio.adb,
2052 a-wtcstr.ads, a-wtdeau.adb, a-wtdeio.adb, a-wtedit.adb,
2053 a-wtedit.ads, a-wtenau.adb, a-wtenio.adb, a-wtfiio.adb,
2054 a-wtflio.adb, a-wtgeau.adb, a-wtinau.adb, a-wtinio.adb,
2055 a-wtmoau.adb, a-wtmoio.adb, a-wttest.adb, back_end.adb,
2056 bindgen.adb, butil.adb, butil.ads, checks.ads, cio.c, comperr.adb,
2057 csets.ads, cstand.adb, debug.ads, elists.ads, errno.c, errout.adb,
2058 errout.ads, erroutc.adb, erroutc.ads, errutil.adb, errutil.ads,
2059 errutil.ads, err_vars.ads, eval_fat.adb, exp_ch11.adb, exp_ch11.ads,
2060 exp_ch2.adb, exp_ch7.ads, exp_imgv.ads, exp_pakd.adb, exp_prag.adb,
2061 exp_prag.ads, exp_tss.adb, exp_tss.ads, exp_vfpt.ads, fe.h, fmap.adb,
2062 freeze.ads, frontend.adb, frontend.ads, g-arrspl.adb, g-arrspl.ads,
2063 g-awk.adb, g-awk.ads, g-boumai.ads, g-calend.adb, g-calend.ads,
2064 g-catiio.adb, g-comlin.adb, g-comlin.ads, g-comlin.ads, g-comlin.ads,
2065 g-comver.adb, g-crc32.adb, g-crc32.ads, g-ctrl_c.ads, g-curexc.ads,
2066 g-debpoo.ads, g-debuti.adb, g-diopit.adb, g-diopit.ads, g-dirope.adb,
2067 g-dirope.ads, g-dyntab.adb, g-dyntab.ads, g-excact.adb, g-excact.ads,
2068 g-except.ads, g-exctra.adb, g-exctra.ads, g-expect.ads, g-flocon.ads,
2069 g-hesorg.ads, g-io.adb, g-locfil.ads, g-md5.adb, g-md5.ads, g-md5.ads,
2070 g-moreex.adb, g-signal.ads, g-signal.adb, gnatbind.ads, gnatchop.adb,
2071 gnatcmd.adb, gnatfind.adb, gnatlbr.adb, gnatmake.ads, gnatmem.adb,
2072 gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb, g-os_lib.adb,
2073 g-os_lib.ads, g-pehage.adb, g-pehage.ads, gprep.ads, g-regexp.adb,
2074 g-regexp.ads, g-regist.adb, g-regist.ads, g-regpat.ads, g-semaph.adb,
2075 g-socthi.adb, g-soliop.ads, g-spipat.adb, g-spipat.ads, g-sptabo.ads,
2076 g-sptain.ads, g-sptavs.ads, g-string.ads, g-tasloc.adb, g-tasloc.ads,
2077 g-trasym.adb, g-trasym.ads, i-fortra.adb, i-fortra.ads, inline.adb,
2078 layout.adb, live.adb, make.ads, makeutl.ads, makeutl.adb, mdll-fil.adb,
2079 mdll-fil.ads, mdll-utl.ads, memroot.ads, memtrack.adb, mlib.ads,
2080 mlib-fil.adb, mlib-fil.ads, mlib-prj.ads, mlib-utl.adb, mlib-utl.ads,
2081 nlists.adb, nlists.ads, osint.adb, osint.ads, osint-c.adb, osint-l.adb,
2082 osint-l.ads, osint-m.ads, output.adb, par.adb, par.adb, par.ads,
2083 par-ch11.adb, par-ch12.adb, par-ch2.adb, par-ch4.adb, par-ch5.adb,
2084 par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb,
2085 par-tchk.adb, prep.adb, prepcomp.adb, prepcomp.ads, prj-attr.ads,
2086 prj-com.ads, prj-dect.adb, prj-dect.ads, prj-env.ads, prj-err.ads,
2087 prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.ads, prj-pars.adb,
2088 prj-pars.ads, prj-part.ads, prj-pp.ads, prj-proc.ads, prj-strt.adb,
2089 prj-strt.ads, prj-tree.adb, prj-util.adb, prj-util.ads, rtsfind.adb,
2090 sem.adb, sem.ads, sem_case.adb, sem_case.ads, sem_ch11.adb,
2091 sem_ch4.adb, sem_ch6.ads, sem_ch7.ads, sem_dist.ads, sem_elab.ads,
2092 sem_elim.ads, sem_eval.ads, sem_intr.ads, sem_maps.adb, sem_maps.ads,
2093 sem_maps.ads, sem_res.ads, sem_type.ads, sfn_scan.adb, sfn_scan.ads,
2094 s-imgwch.ads, s-imgwiu.adb, s-imgwiu.ads, s-inmaop.ads, sinput.adb,
2095 sinput.ads, s-pack03.adb, s-pack03.ads, s-pack05.adb, s-pack05.ads,
2096 s-pack06.adb, s-pack06.ads, s-pack07.adb, s-pack07.ads, s-pack09.adb,
2097 s-pack09.ads, s-pack10.adb, s-pack10.ads, s-pack11.adb, s-pack11.ads,
2098 s-pack12.adb, s-pack12.ads, s-pack13.adb, s-pack13.ads, s-pack14.adb,
2099 s-pack14.ads, s-pack15.adb, s-pack15.ads, s-pack17.adb, s-pack17.ads,
2100 s-pack18.adb, s-pack18.ads, s-pack19.adb, s-pack19.ads, s-pack20.adb,
2101 s-pack20.ads, s-pack21.adb, s-pack21.ads, s-pack22.adb, s-pack22.ads,
2102 s-pack23.adb, s-pack23.ads, s-pack24.adb, s-pack24.ads, s-pack25.adb,
2103 s-pack25.ads, s-pack26.adb, s-pack26.ads, s-pack27.adb, s-pack27.ads,
2104 s-pack28.adb, s-pack28.ads, s-pack29.adb, s-pack29.ads, s-pack30.adb,
2105 s-pack30.ads, s-pack31.adb, s-pack31.ads, s-pack33.adb, s-pack33.ads,
2106 s-pack34.adb, s-pack34.ads, s-pack35.adb, s-pack35.ads, s-pack36.adb,
2107 s-pack36.ads, s-pack37.adb, s-pack37.ads, s-pack38.adb, s-pack38.ads,
2108 s-pack39.adb, s-pack39.ads, s-pack40.adb, s-pack40.ads, s-pack41.adb,
2109 s-pack41.ads, s-pack42.adb, s-pack42.ads, s-pack43.adb, s-pack43.ads,
2110 s-pack44.adb, s-pack44.ads, s-pack45.adb, s-pack45.ads, s-pack46.adb,
2111 s-pack46.ads, s-pack47.adb, s-pack47.ads, s-pack48.adb, s-pack48.ads,
2112 s-pack49.adb, s-pack49.ads, s-pack50.adb, s-pack50.ads, s-pack51.adb,
2113 s-pack51.ads, s-pack52.adb, s-pack52.ads, s-pack53.adb, s-pack53.ads,
2114 s-pack54.adb, s-pack54.ads, s-pack55.adb, s-pack55.ads, s-pack56.adb,
2115 s-pack56.ads, s-pack57.adb, s-pack57.ads, s-pack58.adb, s-pack58.ads,
2116 s-pack59.adb, s-pack59.ads, s-pack60.adb, s-pack60.adb, s-pack60.ads,
2117 s-pack61.adb, s-pack61.ads, s-pack62.adb, s-pack62.ads, s-pack63.adb,
2118 s-pack63.ads, s-parint.adb, s-parint.adb, s-parint.ads, sprint.ads,
2119 s-purexc.ads, s-restri.ads, s-restri.adb, s-scaval.adb, s-scaval.ads,
2120 s-secsta.adb, s-secsta.ads, s-sequio.adb, s-sequio.ads, stand.ads,
2121 s-tasuti.adb, s-traceb.adb, s-traceb.ads, stringt.adb, stringt.ads,
2122 styleg.ads, s-valboo.adb, s-valboo.ads, s-valcha.adb, s-valcha.ads,
2123 s-valdec.adb, s-valdec.ads, s-valint.adb, s-valint.ads, s-valint.ads,
2124 s-vallld.adb, s-vallld.ads, s-vallli.adb, s-vallli.ads, s-valllu.adb,
2125 s-valllu.ads, s-valrea.adb, s-valrea.ads, s-valuns.adb, s-valuns.ads,
2126 s-valuti.adb, s-valuti.ads, s-valwch.ads, s-veboop.adb, s-veboop.ads,
2127 s-vercon.adb, s-vercon.ads, s-wchcnv.adb, s-wchcnv.ads, s-wchcon.ads,
2128 s-wchjis.adb, s-wchjis.ads, s-wchstw.adb, s-wchstw.adb, s-wchstw.ads,
2129 s-wchwts.adb, s-wchwts.ads, s-widboo.adb, s-widboo.ads, s-widcha.adb,
2130 s-widcha.ads, s-widenu.adb, s-widenu.ads, s-widlli.adb, s-widlli.ads,
2131 s-widllu.adb, s-widllu.ads, s-widwch.adb, s-widwch.ads, s-wwdcha.adb,
2132 s-wwdcha.ads, s-wwdenu.adb, s-wwdenu.ads, symbols.adb, symbols.ads,
2133 table.ads, targparm.adb, targparm.ads, tb-alvms.c, tb-alvxw.c,
2134 tbuild.adb, tree_io.ads, treepr.adb, treeprs.adt, ttypef.ads,
2135 ttypes.ads, types.adb, uintp.adb, uintp.ads, uname.ads, urealp.ads,
2136 usage.ads, validsw.ads, vxaddr2line.adb, widechar.adb, widechar.ads,
2137 xeinfo.adb, xnmake.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads,
2138 xsinfo.adb, xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb,
2139 a-dirval.ads, a-dirval.adb, a-dirval-mingw.adb, a-direct.ads,
2140 a-direct.adb, indepsw.ads, prj-attr-pm.ads, system-linux-ppc.ads,
2141 a-numaux-darwin.ads, a-numaux-darwin.adb,
2142 a-swuwha.ads, a-stunha.ads: Minor reformatting
2144 2005-11-14 Robert Dewar <dewar@adacore.com>
2147 * osint-m.adb: Add pragma Elaborate_All for Osint
2149 2005-11-10 Eric Botcazou <ebotcazou@adacore.com>
2152 * trans.c (call_to_gnu): Restore statement lost in translation.
2154 2005-11-08 Eric Botcazou <ebotcazou@adacore.com>
2156 * init.c: Use the Linux-specific section for the IA-64/Linux target.
2157 (__gnat_adjust_context_for_raise): Add conditional code so that the
2158 IA-64 is also supported.
2160 2005-11-03 James E Wilson <wilson@specifix.com>
2163 * trans.c (gnat_to_gnu): Use TYPE_SIZE_UNIT not TYPE_SIZE in
2164 TREE_OVERFLOW check.
2166 2005-09-21 Olivier Hainque <hainque@adacore.com>
2169 * decl.c (maybe_pad_type): Use proper bitsizetype for XVZ objects,
2170 as we create them to store a size in bits.
2172 2005-10-21 Eric Botcazou <ebotcazou@adacore.com>
2180 * utils2.c (build_return_expr): New helper function.
2181 * gigi.h (build_return_expr): Declare it.
2182 * trans.c (Subprogram_Body_to_gnu): Use build_return_expr instead
2183 of manually building the RETURN_EXPR tree.
2184 (call_to_gnu): Pass MODIFY_EXPR through build_binary_op.
2185 (gnat_to_gnu) <N_Return_Statement>: Pass MODIFY_EXPR through
2186 build_binary_op for the "target pointer" case. Use build_return_expr
2187 instead of manually building the RETURN_EXPR tree.
2189 2005-09-16 Laurent GUERBY <laurent@guerby.net>
2192 * s-tpinop.ads: Make this unit Preelaborate.
2194 2005-09-16 Andreas Jaeger <aj@suse.de>
2196 * socket.c: Add string.h for memcpy.
2198 2005-09-05 Arnaud Charlet <charlet@adacore.com>
2200 * dec-io.ads, dec-io.adb: Removed, no longer used.
2202 2005-09-01 Arnaud Charlet <charlet@adacore.com>
2204 * a-calend-mingw.adb: Add call to OS_Primitives.Initialize;
2206 * s-taprop-mingw.adb, s-taprop-vms.adb, s-taprop-solaris.adb,
2207 s-taprop-os2.adb, s-taprop-irix-athread.adb, s-taprop-linux.adb,
2208 s-taprop-hpux-dce.adb, s-taprop-irix.adb, s-taprop-tru64.adb,
2209 s-taprop-lynxos.adb: Move with clauses outside Warnings Off now that
2210 dependent units are Preelaborate.
2211 (Initialize): Call Interrupt_Managemeent.Initialize and
2212 OS_Primitives.Initialize to ensure proper initialization of this unit.
2213 Remove use of System.Soft_Links
2214 Make this unit Preelaborate.
2216 * s-stache.ads, s-taspri-vxworks.ads, s-taspri-mingw.ads,
2217 s-taspri-vms.ads, s-tasinf-solaris.ads, s-taspri-os2.ads,
2218 s-taspri-lynxos.ads, s-taspri-hpux-dce.ads, s-taspri-tru64.ads,
2219 s-tasinf-tru64.ads, s-tasinf-irix.ads, s-tasinf-irix-athread.ads,
2220 s-proinf-irix-athread.adb, s-proinf-irix-athread.ads,
2221 s-tratas.ads, s-tasinf.ads: Minor reformatting.
2222 Add pragma Preelaborate, since these packages are suitable for this
2226 * s-traent-vms.ads, s-intman-dummy.adb,
2227 s-taprop-dummy.adb: Make this unit Preelaborate.
2229 * s-osprim-vxworks.adb, s-osprim-vms.adb, s-osprim-vms.ads,
2230 s-osprim-mingw.adb, s-intman-vxworks.ads, s-intman-vxworks.adb,
2231 s-intman-vms.adb, s-intman-mingw.adb, s-intman-vms.ads,
2232 s-osprim-unix.adb, s-osprim-os2.adb, s-osprim-solaris.adb,
2233 s-intman-solaris.adb, s-intman-irix-athread.adb,
2234 s-intman-irix.adb: Mark this unit Preelaborate.
2235 (Initialize): New procedure.
2238 * s-taspri-linux.ads: Removed.
2240 * s-tpopsp-solaris.adb (Initialize): Create the key in this procedure,
2241 as done by other implementations (e.g. posix).
2243 * s-taprop.ads (Timed_Delay): Update spec since the caller now is
2244 responsible for deferring abort.
2245 Mark this unit Preelaborate.
2247 * s-taprob.adb, s-tarest.adb: Call System.Tasking.Initialize to ensure
2248 proper initialization of the tasking run-time.
2250 * s-tasdeb.ads: Mark this unit Preelaborate.
2251 (Known_Tasks): Add explicit default value to avoid elaboration code.
2253 * s-inmaop-vms.adb (Elaboration code): Add call to
2254 Interrupt_Management.Initialize since the elaboration code depends on
2255 proper initialization of this package.
2257 * s-intman.ads, s-inmaop-posix.adb, s-intman-posix.adb,
2258 s-osprim.ads, s-taprop-posix.adb, s-taspri-posix.ads,
2259 s-osprim-posix.adb: Make this unit Preelaborate.
2261 * a-calend.adb: Add call to OS_Primitives.Initialize
2263 * a-elchha.adb: Update use of Except.Id.Full_Name.
2265 Remove use of Ada.Exceptions.Traceback when possible, cleaner.
2267 * a-dynpri.adb, a-sytaco.adb, a-sytaco.ads:
2268 Move with clauses outside Warnings Off now that dependent units are
2270 Use raise xxx with "..."; Ada 2005 form.
2272 * a-taside.ads, a-taside.adb:
2273 Remove some dependencies, to make it easier to make this unit truly
2275 Rewrite some code to be conformant with Preelaborate rules.
2277 * g-os_lib.adb: Remove non-preelaborate code so that this unit can be
2278 marked Preelaborate in the future.
2280 * s-proinf.ads, g-string.ads, s-auxdec.ads, s-auxdec-vms_64.ads: Make
2281 these units Preelaborate.
2283 * s-exctab.adb: Update use of Except.Id.Full_Name.
2285 * s-soflin.ads, s-soflin.adb: Mark this unit Preelaborate_05.
2286 (Set_Exc_Stack_Addr_Soft, Get_Exc_Stack_Addr_NT, Set_Exc_Stack_Addr_NT,
2287 Set_Exc_Stack_Addr): Removed, no longer used.
2288 Remove reference to *Machine_State_Addr*, no longer needed.
2290 * s-stalib.ads: Mark this unit as Preelaborate[_05].
2291 (Exception_Data): Full_Name is now a System.Address so that this unit
2292 can be made Preelaborate.
2293 Clean up/simplify code thanks to Full_Name being a System.Address.
2294 Remove obsolete pragma Suppress (All_Checks), no longer needed.
2296 * s-taskin.ads, s-taskin.adb:
2297 Move with clauses outside Warnings Off now that dependent units are
2299 Make this unit Preelaborate.
2300 (Initialize): New proceduure, replace elaboration code and makes the
2301 set up of the tasking run-time cleaner.
2302 (Detect_Blocking): Now a function instead of a deferred boolean, to
2303 obey Preelaborate rules.
2305 * s-tassta.adb (Finalize_Global_Tasks): Remove Get/Set_Exc_Stack_Addr
2306 soft links, no longer used.
2308 * s-traces.ads, s-traent.ads: Add pragma Preelaborate, since these
2309 packages are suitable for this categorization.
2311 * s-solita.adb: Replace use of Ada.Exception by raise xxx with "..."
2312 since we compile run-time sources in Ada 2005 mode.
2313 (Timed_Delay_T): Call Abort_Defer/Undefer around Timed_Delay, to
2314 avoid having s-taprop*.adb depend on s-soflin and to avoid code
2316 Remove reference to *Machine_State_Addr*, no longer needed.
2318 2005-09-01 Arnaud Charlet <charlet@adacore.com>
2320 * s-mastop-tru64.adb, s-mastop-irix.adb, s-mastop-vms.adb
2321 (Enter_Handler, Set_Signal_Machine_State): Removed, no longer used.
2322 Remove reference to System.Exceptions.
2324 * s-mastop-x86.adb: Removed, no longer used.
2326 * s-traceb-mastop.adb: Adjust calls to Pop_Frame.
2328 * a-excach.adb: Minor reformatting.
2330 * a-except.ads, a-except.adb: Remove global Warnings (Off) pragma, and
2331 instead fix new warnings that were hidden by this change.
2332 (AAA, ZZZ): Removed, replaced by...
2333 (Code_Address_For_AAA, Code_Address_For_ZZZ): ... these functions, who
2334 are used instead of constants, to help make Ada.Exception truly
2336 (Rcheck_*, Raise_Constraint_Error, Raise_Program_Error,
2337 Raise_Storage_Error): File is now a System.Address, to simplify code.
2338 (Elab code): Removed, no longer used.
2339 (Null_Occurrence): Remove Warnings Off and make this construct
2341 Remove code related to front-end zero cost exception handling, since
2342 it is no longer used.
2343 Remove -gnatL/-gnatZ switches.
2345 * a-exexda.adb (Append_Info_Exception_Name, Set_Exception_C_Msg):
2346 Update use of Except.Msg.
2348 * gnat1drv.adb, inline.adb, bindgen.adb, debug.adb, exp_ch11.ads,
2349 freeze.adb, frontend.adb, lib.adb, exp_ch11.adb: Remove code related
2350 to front-end zero cost exception handling, since it is no longer used.
2351 Remove -gnatL/-gnatZ switches.
2353 * lib-writ.ads: Minor reformatting
2356 * Makefile.rtl: Remove references to s-except*, s-mastop-x86*
2358 * Make-lang.in: Remove references to s-except.ads
2360 * s-except.ads: Removed, no longer used.
2362 * s-mastop.ads, s-mastop.adb:
2363 (Enter_Handler, Set_Signal_Machine_State): Removed, no longer used.
2364 Remove reference to System.Exceptions.
2366 * raise.h, usage.adb, targparm.adb, targparm.ads, switch-m.adb,
2367 switch-b.adb: Remove code related to front-end zero cost exception
2368 handling, since it is no longer used.
2369 Remove -gnatL/-gnatZ switches.
2371 2005-09-01 Robert Dewar <dewar@adacore.com>
2372 Gary Dismukes <dismukes@adacore.com>
2373 Javier Miranda <miranda@adacore.com>
2375 * exp_ch4.adb (Expand_N_In): Replace test of expression in its own
2376 type by valid test and generate warning.
2377 (Tagged_Membership): Generate call to the run-time
2378 subprogram IW_Membership in case of "Iface_CW_Typ in Typ'Class"
2379 Change formal name Subtype_Mark to Result_Definition in several calls to
2380 Make_Function_Specification.
2381 (Expand_Allocator_Expression): Add tests for suppression of the AI-344
2382 check for proper accessibility of the operand of a class-wide allocator.
2383 The check can be left out if checks are suppressed or if the expression
2384 has a specific tagged type whose level is known to be safe.
2386 * exp_ch5.adb (Expand_N_Assignment_Statement): Simplify the code that
2387 generates the run-time check associated with null-excluding entities.
2388 (Expand_N_Return_Statement): Add tests to determine if the accessibility
2389 check on the level of the return expression of a class-wide function
2390 can be elided. The check usually isn't needed if the expression has a
2391 specific type (unless it's a conversion or a formal parameter). Also
2392 add a test for whether accessibility checks are suppressed. Augment
2393 the comments to describe the conditions for performing the check.
2395 2005-09-01 Hristian Kirtchev <kirtchev@adacore.com>
2396 Javier Miranda <miranda@adacore.com>
2397 Gary Dismukes <dismukes@adacore.com>
2398 Ed Schonberg <schonberg@adacore.com>
2400 * a-tags.adb (IW_Membership): Give support to
2401 "Iface_CW_Typ in T'Class". For this purpose the functionality of this
2402 subprogram has been extended to look for the tag in the ancestors tag
2404 Update the structure of the GNAT Dispatch Table to reflect the
2405 additional two tables used in dispatching selects.
2406 Introduce appropriate array types and record components in
2407 Type_Specific_Data to reflect the two tables.
2408 (Get_Entry_Index, Set_Entry_Index): Retrieve and set the entry index in
2409 the TSD of a tag, indexed by position.
2410 (Get_Prim_Op_Kind, Set_Prim_Op_Kind): Retrieve and set the primitive
2411 operation kind in the TSD of a tag, indexed by position.
2413 * a-tags.ads: Introduce an enumeration type to capture different
2414 primitive operation kinds. Define a constant reflecting the number of
2415 predefined primitive operations.
2416 (Get_Entry_Index, Set_Entry_Index): Set and retrieve the entry index
2417 of an entry wrapper.
2418 (Get_Prim_Op_Kind, Set_Prim_Op_Kind): Set and retrieve the kind of
2419 callable entity of a primitive operation.
2421 * exp_ch3.adb (Freeze_Record_Type): Generate the declarations of the
2422 primitive operations used in dispatching selects for limited
2423 interfaces, limited tagged, task and protected types what implement a
2425 (Freeze_Type): Generate the bodies of the primitive operations used in
2426 dispatching selects for limited tagged, task and protected types that
2427 implement a limited interface. Generate statements to populate the two
2428 auxiliary tables used for dispatching in select statements.
2429 (Freeze_Record_Type): Add call to initialize the dispatch table entries
2430 associated with predefined interface primitive operations.
2431 (Build_Dcheck_Function): Change Set_Subtype_Mark to
2432 Set_Result_Definition.
2433 (Build_Variant_Record_Equality): Change Subtype_Mark to
2435 (Freeze_Enumeration_Type): Change Subtype_Mark to Result_Definition.
2436 (Predef_Spec_Or_Body): Change Subtype_Mark to Result_Definition.
2437 (Build_Assignment): Simplify the code that adds the run-time-check.
2438 (Expand_N_Object_Declaration): Code cleanup.
2440 * exp_ch7.adb (Make_Clean): Select the appropriate type for locking
2441 entries when there is a protected type that implements a limited
2444 * exp_ch9.adb: Add package Select_Expansion_Utilities that contains
2445 common routines used in expansion of dispatching selects.
2446 (Add_Private_Declarations): Select the appropriate protection type when
2447 there is a protected type that implements a limited interface.
2448 (Build_Parameter_Block): Generate a wrapped parameter block.
2449 (Build_Protected_Subprogram_Body): Select the appropriate type for
2450 locking entries when there is a protected type that implements a
2452 (Build_Wrapper_Spec): Set the flag and wrapped entity for procedures
2453 classified as entry wrappers.
2454 (Expand_N_Asynchronous_Select): Add support for expansion of dispatching
2455 asynchronous selects.
2456 (Expand_N_Conditional_Entry_Call): Add support for expansion of
2457 dispatching conditional selects.
2458 (Expand_N_Protected_Type_Declaration): Select the appropriate type for
2459 protection when there is a protected type that implements limited
2461 (Expand_N_Timed_Entry_Call): Add support for expansion of dispatching
2463 (Extract_Dispatching_Call): Extract the entity of the name of a
2464 dispatching call, the object parameter, actual parameters and
2465 corresponding formals.
2466 (Make_Initialize_Protection): Correct logic of protection initialization
2467 when there is a protected type that implements a limited interface.
2468 (Parameter_Block_Pack): Populate a wrapped parameter block with the
2469 values of actual parameters.
2470 (Parameter_Block_Unpack): Retrieve the values from a wrapped parameter
2471 block and assign them to the original actual parameters.
2473 * exp_ch9.ads (Subprogram_Protection_Mode): New type.
2474 (Build_Protected_Sub_Specification): Change the type and name of the
2475 last formal to account for the increased variety of protection modes.
2477 * einfo.ads, einfo.adb (Was_Hidden): New attribute. Present in all
2478 entities. Used to save the value of the Is_Hidden attribute when the
2479 limited-view is installed.
2480 (Is_Primitive_Wrapper, Set_Is_Primitive_Wrapper): Retrieve and change
2481 the attribute of procedures classified as entry wrappers.
2482 (Wrapped_Entity, Set_Wrapped_Entity): Retrieve and change the wrapped
2483 entity of a primitive wrapper.
2484 (Write_Entity_Flags): Output the name and value of the
2485 Is_Primitive_Wrapper attribute.
2486 (Write_Field27_Name): Output the name and entity of the field Wrapped_
2488 (Underlying_Type): If we have an incomplete entity that comes from
2489 the limited view then we return the Underlying_Type of its non-limited
2490 view if it is already available.
2491 (Abstract_Interface_Alias): Flag applies to all subrogram kinds,
2492 including operators.
2493 (Write_Field26_Name): Add entry for Overridden_Operation
2494 (Overridden_Operation): New attribute of functions and procedures.
2496 * exp_disp.ads, exp_disp.adb (Default_Prim_Op_Position): Return a
2497 predefined position in the dispatch table for the primitive operations
2498 used in dispatching selects.
2499 (Init_Predefined_Interface_Primitives): Remove the hardcoded number of
2500 predefined primitive operations and replace it with
2501 Default_Prim_Op_Count.
2502 (Make_Disp_Asynchronous_Select_Spec, Make_Disp_Conditional_Select_Spec,
2503 Make_Disp_Get_Prim_Op_Kind_Spec, Make_Disp_Timed_Select_Spec): Update
2504 the names of the generated primitive operations used in dispatching
2506 (Init_Predefined_Interface_Primitives): No need to inherit primitives in
2507 case of abstract interface types. They will be inherit by the objects
2508 implementing the interface.
2509 (Make_DT): There is no need to inherit the dispatch table of the
2510 ancestor interface for the elaboration of abstract interface types.
2511 The dispatch table will be inherited by the object implementing the
2513 (Copy_Secondary_DTs): Add documentation.
2514 (Validate_Position): Improve this static check in case of
2515 aliased subprograms because aliased subprograms must have
2517 (Init_Predefined_Interface_Primitives): New subprogram that initializes
2518 the entries associated with predefined primitives of all the secondary
2520 (Build_Anonymous_Access_Type): Removed.
2521 (Expand_Interface_Actuals): With the previous cleanup there is no need
2522 to build an anonymous access type. This allows further cleanup in the
2523 code generated by the expander.
2524 (Expand_Interface_Conversion): If the actual is an access type then
2525 build an internal function to handle the displacement. If the actual
2526 is null this function returns null because no displacement is
2527 required; otherwise performs a type conversion that will be
2528 expanded in the code that returns the value of the displaced actual.
2529 (Expand_Interface_Actuals): Avoid the generation of unnecessary type
2530 conversions that have no effect in the generated code because no
2531 displacement is required. Code cleanup; use local variables to
2532 avoid repeated calls to the subprogram directly_designated_type().
2534 * exp_util.ads, exp_util.adb (Is_Predefined_Dispatching_Operation):
2535 Classify the primitive operations used in dispatching selects as
2537 (Implements_Limited_Interface): Determine whether some type either
2538 directly implements a limited interface or extends a type that
2539 implements a limited interface.
2540 (Build_Task_Image_Function): Change Subtype_Mark to Result_Definition.
2541 (Expand_Subtype_From_Expr): Do not build actual subtype if the
2542 expression is limited.
2543 (Find_Interface_Tag): Add code to handle class-wide types and
2544 entities from the limited-view.
2546 * rtsfind.ads: Add entries in RE_Id and RE_Unit_Table for
2547 Get_Entry_Index, Get_Prim_Op_Kind, POK_Function, POK_Procedure,
2548 POK_Protected_Entry, POK_Protected_Function, POK_Protected_Procedure,
2549 POK_Task_Entry, POK_Task_Procedure, Prim_Op_Kind, Set_Entry_Index,
2552 * sem_ch9.adb (Analyze_Triggering_Alternative): Check for legal type
2553 of procedure name or prefix that appears as a trigger in a triggering
2556 * uintp.ads: Introduce constants Uint_11 and Uint_13.
2558 2005-09-01 Arnaud Charlet <charlet@adacore.com>
2560 * s-tataat.adb, a-tasatt.adb:
2561 Replace calls to Defer/Undefer_Abortion by Defer/Undefer_Abort.
2563 * s-tasini.ads, s-tasini.adb (Defer_Abortion, Undefer_Abortion): Moved
2564 these procedures to body, and renamed Abort_Defer, Abort_Undefer.
2565 (Get_Exc_Stack_Addr, Set_Exc_Stack_Addr): Removed, no
2568 2005-09-01 Arnaud Charlet <charlet@adacore.com>
2569 Jose Ruiz <ruiz@adacore.com>
2571 * s-taprop-vxworks.adb:
2572 Move with clauses outside Warnings Off now that dependent units are
2574 (Initialize): Call Interrupt_Managemeent.Initialize to ensure proper
2575 initialization of this unit.
2576 (Specific): Add new procedures Initialize and Delete so that this
2577 package can be used for VxWorks 5.x and 6.x
2578 (ATCB_Key, ATCB_Key_Address): Moved to Specific package body to hide
2579 differences between VxWorks 5.x and 6.x
2581 (Timed_Delay): Remove calls to Defer/Undefer_Abort, now performed by
2583 Use only Preelaborate-compatible constructs.
2585 * s-tpopsp-vxworks.adb (ATBC_Key, ATCB_Key_Addr): Moved from
2586 Primitives.Operations.
2587 (Delete, Initialize): New procedures.
2589 * s-osinte-vxworks.adb: Body used to handle differences between
2591 (kill, Set_Time_Slice, VX_FP_TASK): New functions.
2593 * s-osinte-vxworks.ads: Minor reformatting.
2594 Add VxWworks 6.x specific functions (only called from VxWorks 6 files).
2595 (VX_FP_TASK): Now a function, to handle differences between VxWorks 5
2597 (Set_Time_Slice): New function, replacing kerneltimeSlice to share code
2598 between Vxworks 5 and 6.
2599 (taskLock, taskUnlock): Removeed, no longer used.
2601 * adaint.c: The wait.h header is not located in the sys directory on
2602 VxWorks when using RTPs.
2603 (__gnat_set_env_value): Use setenv instead of putenv on VxWorks when
2605 (__gnat_dup): dup is available on Vxworks when using RTPs.
2606 (__gnat_dup2): dup2 is available on Vxworks when using RTPs.
2608 * cal.c: Use the header time.h for Vxworks 6.0 when using RTPs.
2610 * expect.c: The wait.h header is not located in the sys directory on
2611 VxWorks when using RTPs.
2613 2005-09-01 Thomas Quinot <quinot@adacore.com>
2615 * g-soccon-vms.adb: Renamed to g-soccon-vms.ads
2617 * g-soccon-vms.ads: Renamed from g-soccon-vms.adb
2619 * g-soccon.ads, g-soccon-tru64.ads, g-soccon-aix.ads,
2620 g-soccon-darwin.ads, g-soccon-irix.ads, g-soccon-hpux.ads,
2621 g-soccon-solaris.ads, g-soccon-mingw.ads, g-soccon-vxworks.ads,
2622 g-soccon-freebsd.ads: Add new constants:
2624 SO_RCVTIMEO/SO_SNDTIMEO
2628 Move all target-specific file inclusions and macro definitions to
2629 gsocket.h, in order to ensure that any C code in socket.c will see a
2630 set of constants that is consistent with the contents of g-soccon.ads.
2632 * gsocket.h: Code imported from gen-soccon.c:
2633 Move all target-specific file inclusions and macro definitions to
2634 gsocket.h, in order to ensure that any C code in socket.c will see a set
2635 of constants that is consistent with the contents of g-soccon.ads.
2636 This change also makes gen-soccon self-contained (removing dependencies
2637 upon GCC internal headers).
2639 * g-socket.adb (Send_Vector): Make calls to Writev at most IOV_MAX
2641 (To_Inet_Addr): Now a procedure instead of a function, more efficient.
2643 * socket.c: Minor reformatting.
2645 2005-09-01 Ed Schonberg <schonberg@adacore.com>
2646 Thomas Quinot <quinot@adacore.com>
2648 * fname-sf.adb, mlib-tgt.ads,
2649 back_end.adb, casing.adb, g-debpoo.adb, g-excact.adb, g-spipat.adb,
2650 g-spipat.ads, g-thread.adb, lib-list.adb, makeutl.adb, mlib.adb,
2651 osint.adb, par-ch10.adb, par-load.adb, prep.adb, prj.adb, prj-attr.ads,
2652 prj-env.ads, prj-err.adb, prj-err.ads, prj-ext.adb, prj-ext.ads,
2653 prj-makr.adb, prj-makr.ads, prj-pars.ads, prj-part.adb, prj-strt.adb,
2654 prj-tree.ads, prj-util.ads, sem_dist.adb, sinput-c.ads, sinput-l.ads,
2655 sinput-p.ads, styleg-c.ads, xr_tabls.adb, prj-attr-pm.ads,
2656 makegpr.adb: Remove redundant use_clauses.
2658 2005-09-01 Arnaud Charlet <charlet@adacore.com>
2660 * s-stoele.ads, s-stopoo.ads, s-stratt.ads, s-strops.ads, s-unstyp.ads,
2661 s-valboo.ads, s-valcha.ads, s-valdec.ads, s-valenu.ads, s-valint.ads,
2662 s-vallld.ads, s-vallli.ads, s-valllu.ads, s-valrea.ads, s-valuns.ads,
2663 s-valuti.ads, s-valwch.ads, s-veboop.ads, s-vector.ads, s-vercon.ads,
2664 s-wchcnv.ads, s-wchcon.ads, s-wchjis.ads, s-wchstw.ads, s-wchwts.ads,
2665 s-widboo.ads, s-widcha.ads, s-widenu.ads, s-widlli.ads, s-widllu.ads,
2666 s-widwch.ads, s-wwdcha.ads, s-wwdenu.ads, s-wwdwch.ads, system.ads,
2667 table.ads, types.ads, system-vms_64.ads, s-crtl-vms64.ads,
2668 s-addope.ads, system-darwin-ppc.ads, system-vxworks-x86.ads,
2669 s-vxwork-x86.ads, system-linux-ppc.ads, i-vxwork-x86.ads,
2670 a-numaux-darwin.ads, a-crbtgo.ads, a-crbtgk.ads, a-crbltr.ads,
2671 a-coprnu.ads, a-convec.ads, a-contai.ads, a-coinve.ads, a-cohata.ads,
2672 a-cohama.ads, a-cihama.ads, a-cidlli.ads, a-cdlili.ads,
2673 a-numaux-libc-x86.ads, a-numaux-vxworks.ads, system-linux-ia64.ads,
2674 system-freebsd-x86.ads, system-unixware.ads, system-lynxos-ppc.ads,
2675 system-lynxos-x86.ads, system-linux-x86_64.ads, system-tru64.ads,
2676 s-vxwork-alpha.ads, system-aix.ads, system-vxworks-sparcv9.ads,
2677 system-solaris-x86.ads, system-irix-o32.ads, system-irix-n32.ads,
2678 s-parame-hpux.ads, system-hpux.ads, system-vxworks-m68k.ads,
2679 s-vxwork-m68k.ads, system-linux-x86.ads, system-vxworks-mips.ads,
2680 s-vxwork-mips.ads, system-os2.ads, system-interix.ads,
2681 s-vxwork-ppc.ads, system-solaris-sparc.ads, s-vxwork-sparcv9.ads,
2682 system-solaris-sparcv9.ads, s-parame-vms.ads, system-vms.ads,
2683 s-osinte-mingw.ads, system-mingw.ads, s-parame-vms-restrict.ads,
2684 system-vms-zcx.ads, s-parame-ae653.ads, system-vxworks-ppc.ads,
2685 s-parame-vxworks.ads, system-vxworks-alpha.ads, interfac-vms.ads,
2686 a-numaux-x86.ads, a-astaco.ads, a-chahan.ads, a-charac.ads,
2687 a-chlat1.ads, a-chlat9.ads, a-colire.adb, a-colire.ads, a-comlin.ads,
2688 a-cwila1.ads, a-cwila9.ads, ada.ads, a-decima.ads, a-exextr.adb,
2689 a-filico.ads, a-finali.ads, a-interr.ads, a-ioexce.ads, a-dynpri.ads,
2690 a-ngcefu.ads, a-ngcefu.adb, a-ngcoty.adb, a-ngcoty.ads, a-ngelfu.ads,
2691 a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-numaux.ads, a-numeri.ads,
2692 a-reatim.adb, a-stmaco.ads, a-storio.ads, a-strbou.ads, a-stream.ads,
2693 a-strfix.ads, a-string.ads, a-strmap.ads, a-strsea.ads, a-strsup.ads,
2694 a-strunb.ads, a-stunau.ads, a-stwibo.ads, a-stwifi.ads, a-stwima.ads,
2695 a-stwise.ads, a-stwisu.ads, a-stwiun.ads, a-swmwco.ads, a-textio.ads,
2696 csets.ads, debug.ads, dec.ads, g-curexc.ads, get_targ.ads,
2697 g-except.ads, system-linux-hppa.ads, a-chacon.ads, a-widcha.ads,
2698 a-zchara.ads, system-hpux-ia64.ads, a-ciorma.ads, a-coorma.ads,
2699 a-ciormu.ads, a-coormu.ads, a-rbtgso.ads, a-chzla1.ads, a-chzla9.ads,
2700 a-stzbou.ads, a-stzfix.ads, a-stzmap.ads, a-stzsea.ads, a-stzsup.ads,
2701 a-stzunb.ads, a-swunau.ads, a-szunau.ads, gnat.ads, g-regpat.ads,
2702 g-speche.ads, g-spitbo.ads, g-table.ads, g-tasloc.ads, g-trasym.ads,
2703 i-c.ads, i-cpoint.ads, i-cpp.ads, i-cstrin.ads, i-fortra.ads,
2704 interfac.ads, i-os2err.ads, i-os2lib.ads, i-os2syn.ads, i-os2thr.ads,
2705 i-vxwork.ads, output.ads, s-arit64.ads, s-atacco.ads, s-boarop.ads,
2706 s-casuti.ads, s-crtl.ads, s-exctab.ads, s-exnint.ads, s-exnllf.ads,
2707 s-exnlli.ads, s-expint.ads, s-explli.ads, s-expllu.ads, s-expmod.ads,
2708 s-expuns.ads, s-fatflt.ads, s-fatgen.ads, s-fatlfl.ads, s-fatllf.ads,
2709 s-fatsfl.ads, s-finimp.ads, s-finroo.ads, s-fore.ads, s-geveop.ads,
2710 s-htable.ads, s-imgbiu.ads, s-imgboo.ads, s-imgcha.ads, s-imgdec.ads,
2711 s-imgenu.ads, s-imgint.ads, s-imgllb.ads, s-imglld.ads, s-imglli.ads,
2712 s-imgllu.ads, s-imgllw.ads, s-imgrea.ads, s-imguns.ads, s-imgwch.ads,
2713 s-imgwiu.ads, s-io.ads, s-maccod.ads, s-mantis.ads, s-memcop.ads,
2714 s-pack03.ads, s-pack05.ads, s-pack06.ads, s-pack07.ads, s-pack09.ads,
2715 s-pack10.ads, s-pack11.ads, s-pack12.ads, s-pack13.ads, s-pack14.ads,
2716 s-pack15.ads, s-pack17.ads, s-pack18.ads, s-pack19.ads, s-pack20.ads,
2717 s-pack21.ads, s-pack22.ads, s-pack23.ads, s-pack24.ads, s-pack25.ads,
2718 s-pack26.ads, s-pack27.ads, s-pack28.ads, s-pack29.ads, s-pack30.ads,
2719 s-pack31.ads, s-pack33.ads, s-pack34.ads, s-pack35.ads, s-pack36.ads,
2720 s-pack37.ads, s-pack38.ads, s-pack39.ads, s-pack40.ads, s-pack41.ads,
2721 s-pack42.ads, s-pack43.ads, s-pack44.ads, s-pack45.ads, s-pack46.ads,
2722 s-pack47.ads, s-pack48.ads, s-pack49.ads, s-pack50.ads, s-pack51.ads,
2723 s-pack52.ads, s-pack53.ads, s-pack54.ads, s-pack55.ads, s-pack56.ads,
2724 s-pack57.ads, s-pack58.ads, s-pack59.ads, s-pack60.ads, s-pack61.ads,
2725 s-pack62.ads, s-pack63.ads, s-parame.ads, s-pooglo.ads, s-pooloc.ads,
2726 s-poosiz.ads, s-powtab.ads, s-purexc.ads, s-sopco3.ads, s-sopco4.ads,
2727 s-sopco5.ads: Minor reformatting: reindent pragma Pure/Preelaborate
2728 and always use the no parameter form for consistency.
2730 * gnat-style.texi: Document rules about Preelaborate/Pure pragmas.
2732 2005-09-01 Robert Dewar <dewar@adacore.com>
2734 * binde.adb: Minor reformatting
2735 (Find_Elab_Order): Output warning if -p used with static elab order
2737 2005-09-01 Robert Dewar <dewar@adacore.com>
2739 * checks.adb (Check_Needed): New procedure, deals with removing checks
2740 based on analysis of short-circuited forms. Also generates warnings for
2741 improper use of non-short-circuited forms.
2744 2005-09-01 Robert Dewar <dewar@adacore.com>
2746 * a-ztexio.adb, a-textio.adb, a-witeio.adb: Replace bad range checks
2749 2005-09-01 Robert Dewar <dewar@adacore.com>
2751 * errout.ads, errout.adb (Fix Error_Msg_F): Fix implementation to meet
2753 Implement new insertion char < (conditional warning)
2754 * errutil.adb, erroutc.adb: Implement new insertion char <
2755 (conditional warning).
2756 * sem_elab.adb, prj-dect.adb, erroutc.ads, err_vars.ads
2757 (Error_Msg_Warn): New variable for < insertion char.
2758 * prj-nmsc.adb: Implement new errout insertion char < (conditional
2760 (Check_For_Source): Change value of Source_Id only after the current
2761 source has been dealt with.
2763 2005-09-01 Robert Dewar <dewar@adacore.com>
2764 Doug Rupp <rupp@adacore.com>
2766 * exp_attr.adb: Handle vax fpt for 'Valid attribute
2767 * exp_vfpt.ads, exp_vfpt.adb: (Expand_Vax_Valid): New procedure
2768 * s-vaflop-vms-alpha.adb, s-vaflop.ads, s-vaflop.adb
2769 (Valid_D, Valid_F, Valid_G): New functions
2771 2005-09-01 Ed Schonberg <schonberg@adacore.com>
2772 Hristian Kirtchev <kirtchev@adacore.com>
2773 Javier Miranda <miranda@adacore.com>
2775 * exp_ch6.adb (Expand_Call): If an actual is a function call rewritten
2776 from object notation, the original node is unanalyzed and carries no
2777 semantic information, so that accessiblity checks must be performed on
2778 the type of the actual itself.
2779 (Expand_N_Subprogram_Declaration): Change last actual parameter for
2780 compatibility with Build_Protected_Sub_Specification.
2781 (Check_Overriding_Inherited_Interfaces): Add suport to handle
2782 overloaded primitives.
2783 (Register_Interface_DT_Entry): Use the new name of the formal
2784 the the calls to Expand_Interface_Thunk
2786 * exp_dbug.ads: Augment comments on encoding of protected types to
2787 include the generation of dispatching subprograms when the type
2788 implements at least one interface.
2790 * lib.ads: Extend information in Load_Stack to include whether a given
2791 load comes from a Limited_With_Clause.
2793 * lib-load.adb (From_Limited_With_Chain): New predicate to determine
2794 whether a potential circularity is harmless, because it includes units
2795 loaded through a limited_with clause. Extends previous treatment which
2796 did not handle properly arbitrary combinations of limited and
2797 non-limited clauses.
2799 2005-09-01 Nicolas Setton <setton@adacore.com>
2801 * exp_dbug.adb (Get_Encoded_Name): Fixed bug that caused biaised types
2802 to be encoded as typ___XBLU_lowerbound__upperbound instead of
2803 typ___XB_lowerbound__upperbound.
2805 2005-09-01 Thomas Quinot <quinot@adacore.com>
2807 * exp_dist.adb (Add_RACW_TypeCode, Add_RAS_TypeCode): Do not generate
2808 dummy access formal for RACW/RAS TypeCode TSS.
2809 (Build_TypeCode_Call): Do not generate dummy null access actual for
2810 calls to the TypeCode TSS.
2812 2005-09-01 Ed Schonberg <schonberg@adacore.com>
2814 * exp_intr.adb (Expand_Source_Name): For Enclosing_Entity, generate
2815 fully qualified name, to distinguish instances with the same local name.
2817 * g-souinf.ads (Enclosing_Entity): Document that entity name is now
2820 2005-09-01 Robert Dewar <dewar@adacore.com>
2822 * exp_pakd.adb (Create_Packed_Array_Type): Properly handle very large
2825 2005-09-01 Jerome Lambourg <lambourg@adacore.com>
2827 * g-expect.adb (Non_Blocking_Spawn): Initialize the filters field to
2828 (Free): New deallocation procedure for filter elements
2829 (Close): Deallocate any existing filter for the concerned connection
2831 2005-09-01 Laurent Pautet <pautet@adacore.com>
2833 * g-pehage.ads, g-pehage.adb (Select_Char_Position): When no character
2834 position set is provided, we compute one in order to reduce the maximum
2835 length of the keys. This computation first selects a character
2836 position between 1 and the minimum length of the keys in order to
2837 avoid reducing one of the keys to an empty string.
2838 (Initialize, Compute): When the ratio V to K is too low, the algorithm
2839 does not converge. The initialization procedure now comes with a
2840 maximum number of iterations such that when exceeded, an exception is
2841 raised in Compute. The user can initialize this ratio to another value
2843 Reformating and updated headers.
2845 2005-09-01 Javier Miranda <miranda@adacore.com>
2847 * itypes.ads, itypes.adb (Create_Null_Excluding_Itype): New subprogram
2848 that given an entity T creates and returns an Itype that duplicates the
2849 contents of T. The returned Itype has the null-exclusion
2850 attribute set to True, and its Etype attribute references T
2851 to keep the association between the two entities.
2852 Update copyright notice
2854 * sem_aggr.adb (Check_Can_Never_Be_Null,
2855 Aggregate_Constraint_Checks, Resolve_Aggregate,
2856 Resolve_Array_Aggregate, Resolve_Record_Aggregate): Code cleanup.
2858 * sem_ch5.adb (Analyze_Assignment): Code cleanup.
2860 2005-09-01 Gary Dismukes <dismukes@adacore.com>
2861 Robert Dewar <dewar@adacore.com>
2862 Hristian Kirtchev <kirtchev@adacore.com>
2864 * layout.adb (SO_Ref_From_Expr): Change Subtype_Mark to
2867 * par-ch6.adb (P_Subprogram): Handle parsing of Access_Definitions in
2869 Call Set_Result_Definition instead of Set_Subtype_Mark.
2870 (P_Subprogram_Specification): Add parsing of anonymous access result
2871 plus null exclusions. Call Set_Result_Definition instead of
2874 * par-ch3.adb: Add support for LIMITED NEW for Ada 2005 AI-419
2875 (P_Access_Type_Definition): Add parsing for an anonymous access result
2876 subtype, plus parsing for null exclusions. Call Set_Result_Definition
2877 instead of Set_Subtype_Mark.
2879 * sinfo.adb: Add support for LIMITED NEW for Ada 2005 AI-419
2880 (Null_Exclusion_Present): Allow this flag for N_Function_Specification.
2881 (Result_Definition): New function for N_Function_Specifications.
2882 (Subtype_Mark): No longer allowed for N_Access_Function_Definition and
2883 N_Function_Specification.
2884 (Set_Null_Exclusion_Present): Allow this flag for
2885 N_Function_Specification.
2886 (Set_Result_Definition): New procedure for N_Function_Specifications.
2887 (Set_Subtype_Mark): No longer allowed for N_Access_Function_Definition
2888 and N_Function_Specification.
2890 * sinfo.ads: Update grammar rules for 9.7.2: Entry_Call_Alternative,
2891 Procedure_Or_Entry_Call; 9.7.4: Triggering_Statement.
2892 Add support for LIMITED NEW for Ada 2005 AI-419
2893 Update the syntax of PARAMETER_AND_RESULT_PROFILE to reflect the new
2894 syntax for anonymous access results.
2895 Replace Subtype_Mark field by Result_Definition in
2896 N_Function_Specification and N_Access_Definition specs.
2897 Add Null_Exclusion_Present to spec of N_Function_Specification.
2898 (Result_Definition): New function for N_Function_Specification and
2899 N_Access_Function_Definition.
2900 (Set_Result_Definition): New procedure for N_Function_Specification and
2901 N_Access_Function_Definition.
2903 * sprint.adb (S_Print_Node_Actual): Change Subtype_Mark calls to
2904 Result_Definition for cases of N_Access_Function_Definition and
2905 N_Function_Specification.
2906 Print "not null" if Null_Exclusion_Present on N_Function_Specification.
2908 2005-09-01 Vincent Celier <celier@adacore.com>
2910 * lib-writ.adb: Update Copyright notice
2911 (Write_With_Lines): On platforms where file names are case-insensitive,
2912 record the file names in lower case.
2913 (Write_ALI): For D lines, on platforms where file names are
2914 case-insensitive, record the file names in lower case.
2916 2005-09-01 Ed Schonberg <schonberg@adacore.com>
2917 Emmanuel Briot <briot@adacore.com>
2919 * lib-xref.adb (Output_Overridden_Op): Display information on
2920 overridden operation.
2922 * lib-xref.ads: Add documentation on overridden operations.
2924 * ali.ads (Xref_Entity_Record): Add support for storing the overriding
2927 * ali.adb (Get_Typeref): New subprogram. Adds support for parsing the
2928 overriding entity information.
2930 2005-09-01 Vincent Celier <celier@adacore.com>
2932 * mlib-prj.adb (Copy_Interface_Sources): Copy all interface sources,
2933 including those that are inherited.
2935 2005-09-01 Robert Dewar <dewar@adacore.com>
2937 * opt.ads, opt.adb: Add new switches Debug_Pragmas_Enabled[_Config]
2939 * par-prag.adb: Implement new pragma Debug_Policy
2941 * sem_prag.adb Implement new pragma Debug_Policy
2942 (Analyze_Pragma, case Pack): do not let pragma Pack override an explicit
2943 Component_Size attribute specification. Give warning for ignored pragma
2946 * snames.h, snames.ads, snames.adb: Introduce entries in
2947 Preset_Names for Name_Disp_Asynchronous_Select,
2948 Name_Disp_Conditional_Select, Name_Disp_Get_Prim_Op_Kind,
2949 Name_Disp_Timed_Select.
2950 New pragma Debug_Policy
2952 * switch-c.adb (Scan_Front_End_Switches): Set Ada 2005 mode
2954 Switch -gnata also sets Debug_Pragmas_Enabled
2956 * sem.adb, par.adb (Set_Opt_Config_Switch): Add parameter Main_Unit to
2957 handle an explicit -gnata when compiling predefined files.
2959 2005-09-01 Vincent Celier <celier@adacore.com>
2961 * prj-env.adb (Set_Ada_Paths.Add.Recursive_Add): Do not add the object
2962 directories of projects that have no Ada sources.
2964 2005-09-01 Robert Dewar <dewar@adacore.com>
2966 * scng.adb (Check_End_Of_Line): Count characters, rather than bytes
2967 (makes a difference for wide characters)
2969 * widechar.adb, widechar.ads:
2970 Add Wide_Char_Byte_Count feature to count chars vs bytes
2972 2005-09-01 Thomas Quinot <quinot@adacore.com>
2973 Ed Schonberg <schonberg@adacore.com>
2974 Robert Dewar <dewar@adacore.com>
2976 * sem_attr.adb (Resolve_Attribute, case 'Address): For an illegal
2977 'Address attribute reference with an overloaded prefix, use the
2978 location of the prefix (not the location of the attribute reference) as
2980 (Analyze_Attribute, case 'Size): The name of an enumeration literal, or
2981 a function renaming thereof, is a valid prefix for 'Size (where it is
2982 intepreted as a function call).
2983 (Statically_Denotes_Entity): New predicate to determine whether the
2984 prefix of an array attribute can be considered static.
2987 (Eval_Attr): Fix failure to evaluate Component_Size for
2988 unconstrained arrays (resulted in wrong value in packed case, since
2989 back end cannot handle this case)
2991 2005-09-01 Robert Dewar <dewar@adacore.com>
2993 * sem_cat.adb (Check_Categorization_Dependencies): Add more detail to
2994 error msgs for most common cases.
2995 Use new errout insertion char < (conditional warning)
2997 2005-09-01 Javier Miranda <miranda@adacore.com>
2998 Ed Schonberg <schonberg@adacore.com>
3000 * sem_ch10.adb (In_Chain): Moved from the scope of a subprogram to
3001 become local to the whole package.
3002 (Install_Limited_Withed_Unit): Instead of unchaining real entities if
3003 the package was already analyzed the new algorithm "replaces" the
3004 real entities by the shadow ones. This is required to ensure that
3005 the order of these entities in the homonym chains does not change;
3006 otherwise we can have undefined references at linking time because
3007 in case of conflicts the external name of the entities will have
3008 a suffix that depends on the order of the entities in the chain.
3009 (Remove_Limited_With_Clause): Complementary code that completes the
3010 new algorithm and replaces the shadow entities by the real ones.
3011 (Install_Limited_Withed_Unit): When unchaining entities before the
3012 installation of the shadow entities, only regular entities of the
3013 public part must be taken into account. This is required to
3014 keep this routine in synch with the work done by Remove_Limited_
3016 (Install_Limited_With_Clause): Introduce implicit limited_with_clause
3017 even if unit is analyzed, because the analysis of the unit is
3018 idempotent in any case, and the limited view of the unit may have to
3019 be installed for proper visibility.
3020 (Expand_Limited_With_Clause): Even if the unit in the implicit
3021 with_clause has been analyzed already, a limited view of the package
3022 must be built for the current context, if it does not exist yet.
3024 2005-09-01 Ed Schonberg <schonberg@adacore.com>
3025 Javier Miranda <miranda@adacore.com>
3026 Gary Dismukes <dismukes@adacore.com>
3028 * sem_ch12.adb (Instantiate_Subprogram_Body): When creating the
3029 defining entity for the instance body, make a new defining identifier
3030 rather than copying the entity of the spec, to prevent accidental
3031 sharing of the entity list.
3032 (Check_Private_View): When exchanging views of private types, build the
3033 list of exchanged views as a stack, to ensure that on exit the exchanges
3034 are undone in the proper order.
3035 (Analyze_Package_Instantiation, Analyze_Subprogram_Instantiation):
3036 Restore the compilation environment in case of instantiation_error.
3037 (Analyze_Generic_Subprogram_Declaration): Handle creation of type entity
3038 for an anonymous access result.
3039 (Instantiate_Generic_Subprogram): Subtype_Mark => Result_Definition
3040 (Formal_Entity): Handle properly the case of a formal package that
3041 denotes a generic package renaming.
3043 2005-09-01 Thomas Quinot <quinot@adacore.com>
3045 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Reject the
3046 clause if the array aggregate is surrounded by parentheses.
3048 2005-09-01 Cyrille Comar <comar@adacore.com>
3049 Gary Dismukes <dismukes@adacore.com>
3050 Ed Schonberg <schonberg@adacore.com>
3051 Javier Miranda <miranda@adacore.com>
3053 * sem_ch3.ads, sem_ch3.adb (Analyze_Object_Declaration): Go to the
3055 to check if a type is Constrained in cases related to code generation
3056 (rather than semantic checking) since otherwise we do not generate
3057 similar code for mutable private types depending if their
3058 discriminants are visible or not.
3059 (Check_Abstract_Overriding): Do not complain about failure to override
3060 the primitive operations used in dispatching selects since they will
3061 always be overriden at the freeze point of the type.
3062 (Access_Definition): Separate out handling for resetting the scope
3063 of an anonymous access function result type. Retrieve the scope
3064 of the associated function rather than using Current_Scope, which
3065 does not have a consistent value (depends on whether we're in the
3066 middle of analyzing formal parameters). Add ??? comment about
3067 finding a cleaner way to handle the special cases of scope setting.
3068 (Process_Incomplete_Dependents): A protected operation is never a
3069 dispatching operation (only its wrapper may be).
3070 (Build_Derived_Record_Type): In case of tagged private types that
3071 implement interfaces add derivation of predefined primitive
3073 (Derive_Subprograms): Replace the Is_Interface_Derivation parameter
3074 by two parameters that are used in case of derivation from abstract
3075 interface types: No_Predefined_Prims is used to avoid the derivation
3076 of predefined primitives from the interface, and Predefined
3077 Prims_Only is used to complete the derivation predefined primitives
3078 in case of private tagged types implementing interfaces.
3079 Fix typo in comments
3080 (Find_Interface_In_Descendant): Protect the frontend against
3081 wrong code with large circularity chains.
3082 (Is_Private_Overriding): Add support for entities overriding interface
3083 subprograms. The test failed because Entities associated with overriden
3084 interface subprograms are always marked as hidden (and used to build
3085 the secondary dispatch table); in this case the overriden entity is
3086 available through the field abstract_interface_alias (cf. override_
3087 dispatching_operation)
3088 (Access_Definition): Set the scope of the type to Current_Scope for the
3089 case of a function with an anonymous access result type.
3090 (Access_Subprogram_Declaration): Handle creation of the type entity for
3091 an access-to-function type with an anonymous access result.
3092 (Check_Anonymous_Access_Types): Change Subtype_Mark to Result_Definition
3093 in handling for N_Access_Function_Definition.
3094 (Analyze_Subtype_Declaration): Modify the text of error message.
3095 (Derived_Type_Declaration): Modify the text of error message.
3096 (Process_Subtype): Modify the text of error message plus cleanup
3097 of one redundant error message.
3098 (Analyze_Component_Declaration): Code cleanup.
3099 (Analyze_Object_Declaration): Code cleanup.
3100 (Analyze_Subtype_Declaration): Propagate the null-exclusion
3101 attribute in case of access types. Code cleanup.
3102 (Array_Type_Declaration): Code cleanup.
3103 (Process_Discriminants): Create the new null-excluding itype
3104 if required. Code cleanup.
3105 (Process_Subtype): Create the new null-excluding itype if
3106 required. Code cleanup.
3107 (Build_Derived_Record_Type): Code cleanup to avoid calling
3108 twice the subprogram derive_subprograms in case of private
3109 types that implement interfaces. In this particular case the
3110 subprogram Complete_Subprograms_Derivation already does the
3111 job associated with the second call.
3113 * exp_strm.adb (Build_Elementary_Input_Call): Add an explicit
3114 conversion to the full view when generating an operation for a
3115 discriminant whose type may currently be private.
3117 2005-09-01 Ed Schonberg <schonberg@adacore.com>
3118 Javier Miranda <miranda@adacore.com>
3120 * sem_ch4.adb (Transform_Object_Operation): In a context off the form
3121 V (Obj.F), the rewriting does not involve the indexed component, but
3122 only the selected component itself.
3123 Do not apply the transformation if the analyzed node is an actual of a
3124 call to another subprogram.
3125 (Complete_Object_Operation): Retain the entity of the
3126 dispatching operation in the selector of the rewritten node. The
3127 entity will be used in the expansion of dispatching selects.
3128 (Analyze_One_Call): Improve location of the error message associated
3130 (Analyze_Selected_Component): No need to resolve prefix when it is a
3131 function call, resolution is done when parent node is resolved, as
3133 (Analyze_One_Call): Add a flag to suppress analysis of the first actual,
3134 when attempting to resolve a call transformed from its object notation.
3135 (Try_Object_Operation, Transform_Object_Operastion): Avoid makind copies
3136 of the argument list for each interpretation of the operation.
3137 (Try_Object_Operation): The designated type of an access parameter may
3138 be an incomplete type obtained through a limited_with clause, in which
3139 case the primitive operations of the type are retrieved from its full
3141 (Analyze_Call): If this is an indirect call, and the return type of the
3142 access_to_subprogram is incomplete, use its full view if available.
3144 2005-09-01 Javier Miranda <miranda@adacore.com>
3145 Gary Dismukes <dismukes@adacore.com>
3147 * sem_ch6.ads, sem_ch6.adb (Check_Conformance): In case of anonymous
3148 access types the null-exclusion and access-to-constant attributes must
3150 (Analyze_Return_Statement): When the result type is an anonymous access
3151 type, apply a conversion of the return expression to the access type
3152 to ensure that appropriate accessibility checks are performed.
3153 (Analyze_Return_Type): For the case of an anonymous access result type,
3154 generate the Itype and set Is_Local_Anonymous_Access on the type.
3155 Add ??? placeholder for check to disallow returning a limited object
3156 in Ada 2005 unless it's an aggregate or a result of a function call.
3157 Change calls from Subtype_Mark to Result_Definition.
3158 (Analyze_Subprogram_Body): Change formal Subtype_Mark to
3159 Result_Definition in call to Make_Function_Specification.
3160 (Build_Body_To_Inline): Change Set_Subtype_Mark to
3161 Set_Result_Definition.
3162 (Make_Inequality_Operator): Change formal Subtype_Mark to
3163 Result_Definition in call to Make_Function_Specification.
3164 (Process_Formals): Create the new null-excluding itype if required.
3165 (New_Overloaded_Entity): For an entity overriding an interface primitive
3166 check if the entity also covers other abstract subprograms in the same
3167 scope. This is required to handle the general case, that is, overriding
3168 other interface primitives and overriding abstract subprograms inherited
3169 from some abstract ancestor type.
3170 (New_Overloaded_Entity): For an overriding entity that comes from
3171 source, note the operation that it overrides.
3172 (Check_Conformance, Type_Conformant): Addition of one new formal
3173 to skip controlling formals in the analysis. This is used to
3174 handle overloading of abstract interfaces.
3175 (Base_Types_Match): Add missing case for types imported from
3176 limited-with clauses
3177 (New_Overloaded_Entity): Add barrier to protect the use of
3178 the "alias" attribute.
3180 2005-09-01 Ed Schonberg <schonberg@adacore.com>
3182 * sem_ch8.adb (Analyze_Renamed_Entry): For a renaming_as_declaration,
3183 verify that the procedure and the entry are mode conformant.
3184 (Analyze_Subprogram_Renaming): Emit a warning if an operator is renamed
3185 as a different operator, which is often a cut-and-paste error.
3187 2005-09-01 Javier Miranda <miranda@adacore.com>
3188 Ed Schonberg <schonberg@adacore.com>
3190 * sem_disp.adb (Check_Controlling_Formals): Anonymous access types
3191 used in controlling parameters exclude null because it is necessary to
3192 read the tag to dispatch, and null has no tag.
3193 (Override_Dispatching_Operation): If the previous operation is inherited
3194 from an interface, it becomes hidden and does not participate in later
3197 2005-09-01 Javier Miranda <miranda@adacore.com>
3198 Ed Schonberg <schonberg@adacore.com>
3199 Gary Dismukes <dismukes@adacore.com>
3201 * sem_res.adb (Resolve_Membership_Op): In case of the membership test
3202 "Iface_CW_Typ in T'Class" we have nothing else to do in the frontend;
3203 the expander will generate the corresponding run-time check to evaluate
3205 (Resolve_Call): Check for legal type of procedure name or prefix that
3206 appears as a trigger in a triggering alternative.
3207 (Valid_Conversion): I