1 2011-08-01 Geert Bosch <bosch@adacore.com>
3 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
6 2011-08-01 Thomas Quinot <quinot@adacore.com>
8 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
9 explicit raise of a predefined exception as Comes_From_Source if the
10 original N_Raise_Statement comes from source.
12 2011-08-01 Robert Dewar <dewar@adacore.com>
14 * sinfo.ads: Add comment.
15 * sem_ch6.adb: Minor reformatting.
17 2011-08-01 Robert Dewar <dewar@adacore.com>
19 * freeze.adb (Freeze_Entity): Refine check for bad component size
20 clause to avoid rejecting confirming clause when atomic/aliased present.
22 2011-08-01 Ed Schonberg <schonberg@adacore.com>
24 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
25 better determine whether an entity reference is a write.
26 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
28 * lib-xref.adb (Output_References): Do no suppress a read reference at
29 the same location as an immediately preceeding modify-reference, to
30 handle properly in-out actuals.
32 2011-08-01 Tristan Gingold <gingold@adacore.com>
34 * env.c (__gnat_setenv) [VMS]: Refine previous change.
36 2011-08-01 Quentin Ochem <ochem@adacore.com>
38 * i-cstrin.adb (New_String): Changed implementation, now uses only the
39 heap to compute the result.
41 2011-08-01 Robert Dewar <dewar@adacore.com>
43 * atree.ads: Minor reformatting.
45 2011-08-01 Emmanuel Briot <briot@adacore.com>
47 * g-expect.adb (Get_Command_Output): Fix memory leak.
49 2011-08-01 Geert Bosch <bosch@adacore.com>
51 * cstand.adb (P_Float_Type): New procedure to print the definition of
53 (P_Mixed_Name): New procedure to print a name using mixed case
54 (Print_Standard): Use P_Float_Type for printing floating point types
55 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
58 2011-08-01 Thomas Quinot <quinot@adacore.com>
60 * sem_ch3.adb: Minor reformatting.
62 2011-08-01 Ed Schonberg <schonberg@adacore.com>
64 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
65 the completion of a generic function, insert the new body rather than
66 rewriting the original.
68 2011-08-01 Yannick Moy <moy@adacore.com>
70 * sinfo.ads, errout.ads: Typos in comments.
72 2011-08-01 Robert Dewar <dewar@adacore.com>
74 * par-endh.adb: Minor reformatting.
76 2011-08-01 Robert Dewar <dewar@adacore.com>
78 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
79 (Pre_Post_Aspects): New subtype.
80 * par-ch12.adb (P_Generic): New syntax for aspects in packages
81 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
82 * par-ch7.adb (P_Package): Remove Decl parameter
83 (P_Package): Handle new syntax for aspects (before IS)
84 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
86 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
87 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
88 (P_Package): Remove Decl parameter
89 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
91 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
93 * sem_util.ads, sem_util.adb (Static_Boolean): New function
94 * sinfo.ads: Document new syntax for aspects in packages etc.
95 * sprint.adb: Handle new syntax of aspects before IS in package
97 2011-08-01 Thomas Quinot <quinot@adacore.com>
99 * atree.ads: Minor reformatting.
100 * sem_prag.adb: Minor reformatting.
102 2011-08-01 Robert Dewar <dewar@adacore.com>
104 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
105 case expr alternative.
107 2011-08-01 Ed Schonberg <schonberg@adacore.com>
109 * sem_ch12.adb: Fix typo.
111 2011-08-01 Geert Bosch <bosch@adacore.com>
113 * sem_prag.adb (Check_No_Link_Name): New procedure.
114 (Process_Import_Or_Interface): Use Check_No_Link_Name.
115 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
116 instead of Standard_Long_Long_Float_Size global. Preparation for
117 eventual removal of per type constants.
118 * exp_util.ads (Get_Stream_Size): New function returning the stream
119 size value of subtype E.
120 * exp_util.adb (Get_Stream_Size): Implement new function.
121 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
123 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
125 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
127 2011-08-01 Geert Bosch <bosch@adacore.com>
129 * cstand.adb: Fix comments.
130 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
133 2011-08-01 Robert Dewar <dewar@adacore.com>
135 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
137 2011-08-01 Geert Bosch <bosch@adacore.com>
139 * atree.ads: Fix comment.
141 2011-08-01 Robert Dewar <dewar@adacore.com>
143 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
144 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
145 * par.adb: Add with for Namet.Sp.
146 * par-tchk.adb: Minor reformatting.
148 2011-08-01 Vincent Celier <celier@adacore.com>
150 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
151 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
152 of the init procedure of a SAL.
153 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
156 2011-08-01 Thomas Quinot <quinot@adacore.com>
158 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
161 2011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
163 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
165 2011-08-01 Thomas Quinot <quinot@adacore.com>
167 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
168 conformant with its spec (return True only for types that have
169 an overriding Initialize primitive operation that prevents them from
170 having preelaborable initialization).
171 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
172 initialization for controlled types in Ada 2005 or later mode.
174 2011-08-01 Robert Dewar <dewar@adacore.com>
176 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
178 (Same_Aspect): New function.
179 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
180 Type_Invariant, Precondition, Postcondition.
181 * snames.ads-tmpl: Add Name_Type_Invariant.
183 2011-08-01 Robert Dewar <dewar@adacore.com>
185 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
187 (Freeze_All_Ent): Fix error in handling inherited aspects.
188 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
189 already analyzed, but don't skip entire processing of a declaration,
190 that's wrong in some cases of declarations being rewritten.
191 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
192 Don't delay for integer, string literals
193 Treat predicates in usual manner for delay, remove special case code,
195 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
196 (Build_Predicate_Function): Update saved expression in aspect
197 (Build_Invariant_Procedure): Update saved expression in aspect
198 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
199 of replacement of discriminant references if the reference is simple.
201 2011-08-01 Robert Dewar <dewar@adacore.com>
203 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
204 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
205 Static_Predicate and Dynamic_Predicate.
206 (Build_Predicate_Function): Add processing for Static_Predicate
207 and Dynamic_Predicate.
208 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
209 (From_Static_Predicate): New flag
210 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
212 2011-08-01 Robert Dewar <dewar@adacore.com>
214 * usage.adb: Documentation cleanup for Ada version modes in usage.
215 * expander.adb: Minor reformatting.
217 2011-08-01 Robert Dewar <dewar@adacore.com>
219 * atree.ads: Minor comment fix.
220 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
221 a-witeio.ads, sem_prag.adb: Minor reformatting.
223 2011-08-01 Doug Rupp <rupp@adacore.com>
225 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
226 pointers. Use descrip.h header file for convenience. Add some
229 2011-08-01 Robert Dewar <dewar@adacore.com>
231 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
232 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
233 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
235 (Check_Aspect_At_End_Of_Declarations): New procedure
236 (Analye_Aspect_Specification): Minor changes for above procedures
237 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
238 specification node as well.
240 2011-08-01 Pascal Obry <obry@adacore.com>
242 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
243 Windows files. Use GetFilesAttributes() in this case to check for file
244 existence instead of returning with an error code.
246 2011-08-01 Vincent Celier <celier@adacore.com>
248 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
249 High is above Source length.
251 2011-08-01 Robert Dewar <dewar@adacore.com>
253 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
255 2011-08-01 Robert Dewar <dewar@adacore.com>
257 * aspects.ads (Boolean_Aspects): New subtype.
258 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
259 for derived types in cases where the parent type and derived type have
261 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
262 with aspects when parent type also has aspects.
263 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
264 boolean expression at this point).
265 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
266 accordance with final decision on the Ada 2012 feature.
267 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
269 2011-08-01 Matthew Heaney <heaney@adacore.com>
271 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
273 2011-08-01 Pascal Obry <obry@adacore.com>
275 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
276 Fix Replace_Slice when High is above current string size.
277 (Replace_Slice): Fix DL computation when High is above current
280 2011-08-01 Gary Dismukes <dismukes@adacore.com>
282 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
284 2011-08-01 Matthew Heaney <heaney@adacore.com>
286 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
289 2011-08-01 Pascal Obry <obry@adacore.com>
291 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
294 2011-08-01 Ed Schonberg <schonberg@adacore.com>
296 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
297 access to protected subprograms in generic bodies.
298 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
299 protected type, indicate that the convention of the subprogram is
300 Convention_Protected, because it may be used in subsequent declarations
301 within the protected declaration.
303 2011-08-01 Vincent Celier <celier@adacore.com>
305 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
306 and "final" procedures when the name of the library is "ada", to avoid
307 duplicate symbols "adainit" and "adafinal" in executables.
309 2011-08-01 Ed Schonberg <schonberg@adacore.com>
311 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
312 quantified expression that appears within a postcondition and uses the
313 Ada2012 'Result attribute.
315 2011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
317 * init.c (__gnat_error_handler): Cast reason to int.
318 (__gnat_install_handler): Explain sa_sigaction use.
320 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
322 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
323 subprogram has copy-in copy-out parameters, try to promote the mode of
324 the return type if it is passed in registers.
326 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
328 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
329 left operand as addressable.
331 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
333 * gcc-interface/gigi.h (build_function_stub): Remove.
334 (build_return_expr): Likewise.
335 (convert_vms_descriptor): Declare.
336 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
337 (build_function_stub): Move to...
338 * gcc-interface/utils2.c (build_return_expr): Move to...
339 * gcc-interface/trans.c (build_function_stub): ...here.
340 (build_return_expr): ...here.
341 (Subprogram_Body_to_gnu): Add local variable for language_function.
342 Disconnect the parameter attributes cache, if any, once done with it.
343 Call end_subprog_body only after setting the end_locus.
344 Build the stub associated with the function, if any, at the very end.
345 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
346 variables and streamline control flow.
348 2011-07-23 Arnaud Charlet <charlet@adacore.com>
351 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
354 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
357 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
358 Assign to act.sa_sigaction.
359 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
360 current->return_address to char * before arithmetic.
362 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
364 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
365 Correct argument types.
366 Extract code from reason.
367 (__gnat_install_handler): Assign to act.sa_sigaction.
369 2011-07-21 Eric Botcazou <ebotcazou@adacore.com>
371 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
372 (GNAT1_OBJS): ...here.
374 2011-07-15 Eric Botcazou <ebotcazou@adacore.com>
377 * g-socthi-mingw.adb (Fill): Fix formatting.
379 * gcc-interface/gigi.h: Move around comment.
381 2011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
384 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
386 2011-07-14 Florian Weimer <fw@deneb.enyo.de>
389 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
391 2011-07-13 Eric Botcazou <ebotcazou@adacore.com>
393 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
394 range comparison if Pmode is SImode.
396 2011-07-12 Laurent GUERBY <laurent@guerby.net>
397 Eric Botcazou <ebotcazou@adacore.com>
399 * adadecode.c: Wrap up in extern "C" block.
400 * adadecode.h: Likewise.
401 * adaint.c: Likewise. Remove 'const' keyword.
402 * adaint.h: Likewise.
406 * cstreams.c: Likewise.
412 * initialize.c: Likewise.
415 * nlists.h: Likewise.
418 * repinfo.h: Likewise.
419 * seh_init.c: Likewise.
420 * targext.c: Likewise.
421 * tracebak.c: Likewise.
423 * urealp.h: Likewise.
424 * xeinfo.adb: Wrap up generated C code in extern "C" block.
425 * xsinfo.adb: Likewise.
426 * xsnamest.adb: Likewise.
427 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
428 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
429 * gcc-interface/misc.c: Likewise.
430 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
431 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
432 ada/targext.o here...
433 (GNAT_ADA_OBJS): ...and not here.
434 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
435 (GNATBIND_OBJS): Reorder.
437 2011-07-07 Richard Henderson <rth@redhat.com>
439 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
440 dwarf2out_frame_init.
442 2011-07-07 Eric Botcazou <ebotcazou@adacore.com>
444 * gcc-interface/misc.c (gnat_init): Tweak previous change.
446 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
449 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
451 2011-07-06 Richard Guenther <rguenther@suse.de>
453 * gcc-interface/misc.c (gnat_init): Merge calls to
454 build_common_tree_nodes and build_common_tree_nodes_2.
455 Re-initialize boolean_false_node.
457 2011-07-02 Eric Botcazou <ebotcazou@adacore.com>
458 Olivier Hainque <hainque@adacore.com>
459 Nicolas Setton <setton@adacore.com>
461 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
462 the type according to the ARTIFICIAL_P parameter.
463 (create_type_decl): Likewise.
464 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
466 2011-07-01 Eric Botcazou <ebotcazou@adacore.com>
468 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
469 (gnatbind): Likewise.
471 2011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
473 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
475 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
477 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
478 local variable throughout. Remove useless call to Base_Type.
479 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
480 Take it also into account for the volatileness of the field. Set the
481 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
483 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
485 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
486 on a dereference built for a by-ref object if it has an address clause.
488 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
490 * einfo.ads (Address_Taken): Document use for the second argument of
491 Asm_Input and Asm_Output attributes.
492 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
493 argument is an entity name, then set Address_Taken on it.
494 <Attribute_Asm_Output>: Likewise.
495 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
496 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
497 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
498 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
500 2011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
503 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
505 2011-06-14 Joseph Myers <joseph@codesourcery.com>
507 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
508 (ada/utils.o): Update dependencies.
509 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
510 ../../../libcpp/libcpp.a.
511 * gcc-interface/utils.c: Include common/common-target.h.
512 (process_attributes): Use targetm_common.have_named_sections.
514 2011-06-07 Richard Guenther <rguenther@suse.de>
516 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
519 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
521 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
522 TREE_THIS_NOTRAP flag.
524 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
526 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
529 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
531 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
532 constants whose full view has discriminants specially.
534 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
536 * gcc-interface/utils.c: Include diagnostic.h.
537 (gnat_write_global_declarations): Output debug information for all
538 global type declarations before finalizing the compilation unit.
539 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
541 2011-05-25 Jakub Jelinek <jakub@redhat.com>
543 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
545 2011-05-25 Kai Tietz <ktietz@redhat.com>
547 * adaint.c (__gnat_to_canonical_file_list_next): Use array
548 initialization instead of const/none-const pointer assignment.
550 2011-05-24 Joseph Myers <joseph@codesourcery.com>
552 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
554 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
555 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
556 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
557 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
558 libcommon-target.a instead of prefix.o.
560 2011-05-21 Joseph Myers <joseph@codesourcery.com>
563 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
565 2011-05-20 Joseph Myers <joseph@codesourcery.com>
567 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
568 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
569 instead of version.o.
571 2011-05-18 Kai Tietz <ktietz@redhat.com>
573 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
574 boolean_false_node instead of integer_zero_node.
575 (convert_with_check): Likewise.
576 * gcc-interface/decl.c (choices_to_gnu): Likewise.
578 2011-05-12 Eric Botcazou <ebotcazou@adacore.com>
580 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
581 type of the parameter is an unconstrained array, convert the actual to
582 the type of the formal in the In Out and Out cases as well.
584 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
586 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
587 call build_function_type_array or build_varargs_function_type_array
589 (create_subprog_type): Don't call build_function_type; call
590 build_function_type_vec instead.
592 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
594 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
595 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
596 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
598 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
600 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
602 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
603 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
605 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
607 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
609 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
611 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
612 instead of accessing TYPE_ARG_TYPES directly.
613 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
615 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
618 * gcc-interface/gigi.h (get_variant_part): Declare.
619 * gcc-interface/decl.c (get_variant_part): Make global.
620 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
621 types have the same constant size, are record types and T1 has a
622 variant part while T2 doesn't.
624 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
626 * gcc-interface/utils.c (begin_subprog_body): Do not call
628 (end_subprog_body): Likewise.
630 2011-05-04 Richard Guenther <rguenther@suse.de>
632 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
634 (pos_to_constructor): Likewise.
636 2011-05-03 Nathan Froyd <froydnj@codesourcery.com>
637 Eric Botcazou <ebotcazou@adacore.com>
639 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
640 of build_function_type. Adjust calls to...
641 (build_raise_check): ...this. Do not take a void_tree parameter.
642 Call build_function_type_list instead of build_function_type.
643 Fix head comment and swap couple of conditional blocks.
645 2011-04-30 Eric Botcazou <ebotcazou@adacore.com>
647 * gnatvsn.ads (Library_Version): Bump to 4.7.
648 (Current_Year): Bump to 2011.
650 2011-04-29 Michael Matz <matz@suse.de>
652 * gcc-interface/misc.c (gnat_handle_option): Set
653 warn_maybe_uninitialized.
655 2011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
657 * gnat_ugn.texi (Complexity Metrics Control): Update link to
658 the Watson/McCabe paper.
660 2011-04-23 Jim Meyering <meyering@redhat.com>
662 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
664 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
666 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
669 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
671 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
673 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
674 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
675 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
676 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
677 <all>: Do not set flags on the reused DECL node coming from an alias.
678 Set DECL_IGNORED_P on the DECL node built for subprograms if they
679 don't need debug info here...
680 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
681 (gigi): Adjust calls to create_subprog_decl.
682 (build_raise_check): Likewise.
683 (establish_gnat_vms_condition_handler): Likewise.
684 (Compilation_Unit_to_gnu): Likewise.
685 (gnat_to_gnu): Likewise.
687 2011-04-21 Eric Botcazou <ebotcazou@adacore.com>
689 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
690 (NO_REORDER_ADAFLAGS): New variable.
691 (EXTRA_GNATTOOLS): Always define.
692 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
693 Clean up and adjust list of files compiled with special options.
694 * gcc-interface/Make-lang.in: Likewise.
695 (ada/decl.o): Cosmetical change.
696 (ada/misc.o): Remove dependency on $(PLUGIN_H).
698 2011-04-20 Jim Meyering <meyering@redhat.com>
700 * initialize.c (__gnat_initialize): Remove useless if-before-free.
702 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
704 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
705 $(CFLAGS) on the link line.
707 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
709 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
710 padded type built for the return type if it is unconstrained.
712 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
714 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
716 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
718 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
719 before calling TREE_CHAIN.
720 * gcc-interface/misc.c (gnat_init_ts): New function.
721 (LANG_HOOKS_INIT_TS): Define.
723 2011-04-12 Martin Jambor <mjambor@suse.cz>
725 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
726 instead of cgraph_node.
728 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
730 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
731 alignment on fields of the RETURN type built for the Copy-In Copy-Out
734 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
736 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
737 of aggregate types that contain a placeholder.
739 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
741 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
743 (handle_type_generic_attribute): Likewise.
745 2011-04-04 Eric Botcazou <ebotcazou@adacore.com>
748 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
750 2011-04-04 Kai Tietz <ktietz@redhat.com>
753 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
756 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
758 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
759 type case, do not strip a padding type around the array type.
761 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
763 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
766 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
768 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
769 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
770 code for -feliminate-unused-debug-types.
771 (gnat_post_options): Likewise.
773 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
775 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
776 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
779 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
781 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
782 DECL_ARTIFICIAL flag on enumeration types.
784 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
786 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
787 fat pointer types artificial unconditionally.
788 <E_Array_Subtype>: Attach the base array type as a parallel type if it
791 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
793 * gcc-interface/gigi.h (get_dummy_type): Declare.
794 (build_dummy_unc_pointer_types): Likewise.
795 (finish_fat_pointer_type): Likewise.
796 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
797 fat pointer type has been built, complete it in place.
798 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
799 and thin pointers. Remove useless variable.
800 (finish_fat_pointer_type): Make global and move to...
801 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
802 (get_dummy_type): New function.
803 (build_dummy_unc_pointer_types): Likewise.
804 (gnat_pushdecl): Propage the name to the anonymous variants only.
805 (update_pointer_to): Only adjust the pointer types in the unconstrained
808 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
810 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
811 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
812 if this is a Taft amendment type and the full declaration is available.
813 * gcc-interface/trans.c (process_type): Likewise.
814 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
815 (process_freeze_entity): Likewise.
816 * gcc-interface/utils.c (dummy_global): New static variable.
817 (gnat_write_global_declarations): If there are types declared as used
818 at the global level, insert them in the global hash table.
820 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
822 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
823 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
824 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
826 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
827 flag of the type accordingly.
828 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
830 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
832 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
833 finalizing types when updating the pointers to the designated type.
834 <all>: Finalize the deferred types even if we didn't defer processing
835 of incomplete types in this invocation.
837 2011-04-01 Olivier Hainque <hainque@adacore.com>
838 Nicolas Setton <setton@adacore.com>
839 Eric Botcazou <ebotcazou@adacore.com>
841 * gcc-interface/misc.c (gnat_descriptive_type): New function.
842 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
844 2011-03-28 Kai Tietz <ktietz@redhat.com>
846 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
848 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
849 * system-mingw.ads (System): Change ZCX_By_Default default to True.
851 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
853 2011-03-28 Tristan Gingold <gingold@adacore.com>
856 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
857 Use ada output of gnatbind.
858 (ada/b_gnatb.adb): Ditto.
859 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
860 (ada.mostlyclean, ada.stage1)
861 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
862 (ada.stagefeedback): Adjust.
863 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
864 Use ada output of gnatbind.
865 (b_gnatm.adb): Ditto.
866 (b_gnatl.o, b_gnatm.o): New rules.
868 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
870 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
871 for the padded type built to support a specified size or alignment.
873 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
875 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
876 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
877 unconditionally to the end of the unit when the designated type is
879 <all>: Rename local variable. Attempt to un-defer types only and do it
880 for limited_with'ed types as well.
881 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
882 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
883 consistently and remove redundant call to finalize_from_with_types.
885 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
887 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
888 subprograms without a previous spec declared in the same unit.
889 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
890 subprograms at the end of the unit instead of at the beginning.
891 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
892 isn't public for the special handling of non-inline functions nested
893 inside inline external functions.
895 2011-03-25 Jeff Law <law@redhat.com>
897 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
899 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
901 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
902 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
903 to compute Set_Size_Depends_On_Discriminant.
904 (Layout_Type): Call it on array types in back-end layout mode.
905 * sem_util.adb (Requires_Transient_Scope): Return true for array
906 types only if the size depends on the value of discriminants.
907 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
908 type if the RHS is a call to a function that returns an unconstrained
909 type with default discriminant.
911 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
913 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
914 non-conversion to the nominal result type at the end.
916 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
918 * gcc-interface/trans.c (create_temporary): New function taken from...
919 (create_init_temporary): ...here. Call it.
920 (call_to_gnu): Create the temporary for the return value early, if any.
921 Create it for a function with copy-in/copy-out parameters if there is
922 no target; in other cases of copy-in/copy-out, use another temporary.
923 Push the new binding level lazily. Add and rename local variables.
925 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
927 * gcc-interface/decl.c (validate_size): Improve comments and tweak
929 (set_rm_size): Likewise.
931 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
933 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
934 for the padded type built in order to support a specified alignment.
935 Fix incorrect formatting.
937 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
940 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
942 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
944 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
945 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
946 to the end of the list. Adjust recursive call. Rename local variable.
947 If REORDER is true, reorder components of the record type.
948 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
949 components_to_record and adjust the parameter list.
951 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
953 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
954 disabled, use the variable for bounds of loop iteration scheme.
956 2011-03-21 Kai Tietz <ktietz@redhat.com>
959 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
961 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
963 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
964 out whether the expression is read-only. Short-circuit placeholder
965 case and rename a couple of local variables.
967 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
969 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
970 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
971 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
972 (convert): Deal with conversions from a smaller form type specially.
974 2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
976 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
977 its argument, except for the special -I- switch.
979 2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
981 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
984 2011-02-08 Eric Botcazou <ebotcazou@adacore.com>
986 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
988 2011-02-03 Eric Botcazou <ebotcazou@adacore.com>
990 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
992 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
993 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
994 instead of GNAT_FORMAL. Protect the expression against multiple uses.
995 Do not generate the check directly, instead instantiate the template
996 check present in the descriptor.
997 (make_descriptor_field): Move around.
998 (build_vms_descriptor32): Build a template check in the POINTER field.
999 (build_vms_descriptor): Remove useless suffixes.
1000 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
1002 2011-01-26 Eric Botcazou <ebotcazou@adacore.com>
1005 * targext.c: Include target files if IN_RTS is defined.
1007 2011-01-26 Richard Guenther <rguenther@suse.de>
1010 * targext.c: Include config.h.
1011 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
1014 2011-01-04 Pascal Obry <obry@adacore.com>
1015 Eric Botcazou <ebotcazou@adacore.com>
1017 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
1019 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
1021 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
1022 end-of-case on the end label and its associated gotos, if any.
1024 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
1026 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
1027 expressions of the parameter cache within the statement group of
1030 2011-01-04 Olivier Hainque <hainque@adacore.com>
1031 Eric Botcazou <ebotcazou@adacore.com>
1033 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
1034 (set_end_locus_from_node): New function.
1035 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
1036 make and the function end_locus.
1037 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
1038 for the elaboration subprogram.
1039 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
1040 set the end_locus of the expression as well.
1042 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
1045 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
1046 variables that are referenced in exception handlers volatile.
1050 Copyright (C) 2011 Free Software Foundation, Inc.
1052 Copying and distribution of this file, with or without modification,
1053 are permitted in any medium without royalty provided the copyright
1054 notice and this notice are preserved.