1 2011-08-03 Emmanuel Briot <briot@adacore.com>
3 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
4 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
5 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
6 prj-tree.ads (Prj.Tree.Environment): new type.
8 2011-08-03 Emmanuel Briot <briot@adacore.com>
10 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
11 prj-tree.adb, prj-tree.ads (Environment): new type.
13 2011-08-03 Emmanuel Briot <briot@adacore.com>
15 * prj-tree.ads: Remove unused variable.
17 2011-08-03 Yannick Moy <moy@adacore.com>
19 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
20 issuing messages related to SPARK restriction violation.
22 2011-08-03 Ed Schonberg <schonberg@adacore.com>
24 * sem_ch6.adb: guard against error nodes in return statements.
26 2011-08-03 Arnaud Charlet <charlet@adacore.com>
28 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
29 a warning can only appear on a configuration file, so emit warning
30 without further checks.
32 2011-08-03 Arnaud Charlet <charlet@adacore.com>
34 * s-interr.ads: add overriding keyword.
36 2011-08-03 Geert Bosch <bosch@adacore.com>
38 * exp_attr.adb: Fix minor typo.
40 2011-08-03 Ed Schonberg <schonberg@adacore.com>
42 * par-ch4.adb: improve error recovery.
44 2011-08-03 Emmanuel Briot <briot@adacore.com>
46 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
47 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
50 2011-08-03 Emmanuel Briot <briot@adacore.com>
52 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
53 "external" as an attribute name in aggregate projects.
55 2011-08-03 Jose Ruiz <ruiz@adacore.com>
57 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
58 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
59 from 0, so we need to adjust.
61 2011-08-03 Emmanuel Briot <briot@adacore.com>
63 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
64 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
66 2011-08-03 Yannick Moy <moy@adacore.com>
68 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
69 restriction on overloaded entity if the entity is not an operator.
71 2011-08-03 Yannick Moy <moy@adacore.com>
73 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
74 restrict.ads: Rename remaining Check_Formal_Restriction* into
75 Check_SPARK_Restriction*.
77 2011-08-03 Emmanuel Briot <briot@adacore.com>
79 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
80 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
82 (Project_Empty): removed
83 (Empty_Project): new parameter Qualifier
84 This is used to have fields specific to aggregate projects, cleaner
85 New field to store the list of aggregated projects.
86 (Check_Aggregate_Project): removed
87 (Process_Aggregated_Projects, Free): new subprograms.
89 2011-08-03 Olivier Hainque <hainque@adacore.com>
91 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
93 2011-08-03 Ed Schonberg <schonberg@adacore.com>
95 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
96 explicit dereference of an unconstrained type, create a constrained
97 subtype for it, as is done for function calls that return an
100 2011-08-03 Thomas Quinot <quinot@adacore.com>
102 * g-pehage.adb (Finalize): Avoid possible double-free.
104 2011-08-03 Steve Baird <baird@adacore.com>
106 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
107 Elab_Spec/Body attrs in CodePeer_Mode.
109 2011-08-03 Javier Miranda <miranda@adacore.com>
111 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
112 low bound is not known at compile time but they have no others choice.
113 Done because in this case the bounds can be obtained directly from the
116 2011-08-03 Ed Falis <falis@adacore.com>
118 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
119 on VxWorks SMP. Remove unusable constant ANY_CPU.
121 2011-08-03 Emmanuel Briot <briot@adacore.com>
123 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
124 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
125 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
126 Prj.Env.Initialize_Empty): new subprograms
127 (Get_Env, Find_Project): remove parameter Target_Name.
129 2011-08-03 Gary Dismukes <dismukes@adacore.com>
131 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
132 as a condition for the delayed call to Derived_Subprograms done for the
133 case of the rewriting of a derived type that constrains the
134 discriminants of its parent type.
135 Avoids redundant subprogram derivations for private subtype derivations.
137 2011-08-03 Javier Miranda <miranda@adacore.com>
139 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
140 Build_Record_Aggr_Code.
141 (Build_Record_Aggr_Code): Add missing support to initialize hidden
142 discriminants in extension aggregates.
144 2011-08-03 Emmanuel Briot <briot@adacore.com>
146 * prj-pp.adb (Print): also output project qualifiers, since in
147 particular "aggregate" is mandatory in an aggregate project.
149 2011-08-03 Emmanuel Briot <briot@adacore.com>
151 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
152 (Debug_Output): new function.
154 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
156 * gnat_ugn.texi: Document -Wstack-usage.
157 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
159 2011-08-03 Thomas Quinot <quinot@adacore.com>
161 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
162 have keyword LIMITED.
164 2011-08-03 Yannick Moy <moy@adacore.com>
166 * alfa.adb, alfa.ads, alfa_test.adb: New files.
167 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
168 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
169 section (does not happen in compiler, only if code directly calls
171 * get_alfa.adb, get_alfa.ads: New files.
172 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
174 * lib-xref-alfa.adb: New file.
175 * lib-xref.adb, lib-xref.ads
176 (Xref_Entry): redefine information needed in cross-references for ALFA.
177 Push ALFA treatments in separated local package.
178 (Enclosing_Subpragram_Or_Package): treat specially subprogram
179 identifiers. Return entity of package body instead of spec. Return
180 Empty for a scope with no location.
181 (Generate_Reference): adapt to new components for ALFA information.
182 Remove the need for D references on definitions.
183 (Is_Local_Reference): moved to ALFA local package
184 (Output_References): extract subfunction as Extract_Source_Name
185 (Output_Local_References): remove procedure, replaced by filtering of
186 cross-references in package ALFA and printing in Put_ALFA.
187 (Write_Entity_Name): remove procedure
188 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
189 print exact name of entity as it appears in source file
190 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
191 * put_alfa.adb, put_alfa.ads: New files.
192 * xref_lib.adb (Search_Xref): protect read of cross-references against
193 reading other sections of the ALI file, in gnatxref
194 (Search): protect read of cross-references against reading other
195 sections of the ALI file, in gnatfind.
196 * gcc-interface/Make-lang.in: Update dependencies.
198 2011-08-03 Thomas Quinot <quinot@adacore.com>
200 * sem_ch3.adb: Minor reformatting.
202 2011-08-03 Jose Ruiz <ruiz@adacore.com>
204 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
205 raising an exception.
207 2011-08-03 Ed Schonberg <schonberg@adacore.com>
209 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
210 type, always use 1 as the lower bound or string, even if lower bound of
211 context is not static, to handle properly null strings in a non-static
214 2011-08-03 Bob Duff <duff@adacore.com>
216 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
217 always legal on the right-hand side of an assignment statement; there
218 is always an applicable index constraint in this case. Therefore, the
219 check for Pkind = N_Assignment_Statement is now unconditional -- it
220 doesn't depend on whether Is_Constrained (Typ).
222 2011-08-03 Robert Dewar <dewar@adacore.com>
224 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
226 2011-08-03 Ed Schonberg <schonberg@adacore.com>
228 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
229 for an itype created within a generic unit.
231 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
233 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
234 suppresses all inlining.
236 2011-08-03 Robert Dewar <dewar@adacore.com>
238 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
239 exp_aggr.adb: Minor reformatting.
241 2011-08-03 Thomas Quinot <quinot@adacore.com>
243 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
244 tagged assignment when discriminant checks are suppressed. This is
245 useless and extremely costly in terms of static stack usage.
247 2011-08-03 Bob Duff <duff@adacore.com>
249 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
250 of generics, because this leads to the wrong entity in the wrong scope,
251 causing (e.g.) pragma Export_Procedure to get an error if the entity is
253 (Process_Interface_Name): Follow Alias for instances of generics, to
254 correct for the above change.
256 2011-08-03 Ed Schonberg <schonberg@adacore.com>
258 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
259 is an integer literal it is always safe to replace the reference. In
260 addition, if the reference appears in the generated code for an object
261 declaration it is necessary to copy because otherwise the reference
262 might be to the uninitilized value of the discriminant of the object
265 2011-08-03 Pascal Obry <obry@adacore.com>
267 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
268 ACL used, in this case we want to check for ending .exe, not .exe
269 anywhere in the path.
271 2011-08-03 Sergey Rybin <rybin@adacore.com>
273 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
274 the tree structure (semantic decoration of references to record
277 2011-08-03 Gary Dismukes <dismukes@adacore.com>
279 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
280 choices of a named array aggregate, bail out when any choices are
281 marked as Errors_Posted.
283 2011-08-03 Ed Schonberg <schonberg@adacore.com>
285 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
286 in which entity is frozen, to handle properly loop variables in
289 2011-08-03 Ed Schonberg <schonberg@adacore.com>
291 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
292 subtype is not static, compute the upper bound using attributes, to
293 handle properly index types that are not integer types.
295 2011-08-03 Bob Duff <duff@adacore.com>
297 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
298 Update copyright notice.
300 2011-08-03 Ed Schonberg <schonberg@adacore.com>
302 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
303 Original_Discriminant if within an instance.
304 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
306 2011-08-03 Thomas Quinot <quinot@adacore.com>
308 * einfo.ads: Minor reformatting.
310 2011-08-03 Ed Schonberg <schonberg@adacore.com>
312 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
313 composite type with an unfrozen subcomponent, in the profile of a
316 2011-08-03 Robert Dewar <dewar@adacore.com>
318 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
320 2011-08-03 Ed Schonberg <schonberg@adacore.com>
322 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
323 unconstrained type with discriminants is initialized with an aggregate,
324 use the constrained subtype of the aggregate as the type of the object,
325 because it is immutable, and this allows the back-end to generate no
326 code for the object declaration.
328 2011-08-03 Robert Dewar <dewar@adacore.com>
330 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
331 comparison operand is variable, and turns out to be zero or negative.
333 2011-08-03 Javier Miranda <miranda@adacore.com>
336 (Expand_Dispatching_Constructor_Call): Disable expansion of
337 code required for native targets. Done to avoid generating
338 references to unavailable runtime entities in VM targets.
340 (Expand_N_Object_Declaration): Add missing support to handle
341 the explicit initialization of class-wide interface objects.
344 2011-08-03 Matthew Heaney <heaney@adacore.com>
346 * a-cobove.adb (Merge): Move source onto target, instead of using Assign
348 2011-08-03 Matthew Heaney <heaney@adacore.com>
350 * a-cbdlli.adb (Splice): move source items from first to last
352 2011-08-03 Yannick Moy <moy@adacore.com>
354 * sem_util.ads: comment added.
356 2011-08-03 Javier Miranda <miranda@adacore.com>
359 (Expand_Record_Aggregate): In VM targets disable the expansion into
360 assignments of aggregates whose type is not known at compile time.
362 2011-08-03 Ed Schonberg <schonberg@adacore.com>
364 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
365 protected entries and task entries, to build the proper renaming
366 declaration for entry formals, used in debugging.
367 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
368 parameters in the same way.
370 2011-08-02 Robert Dewar <dewar@adacore.com>
372 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
373 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
376 2011-08-02 Robert Dewar <dewar@adacore.com>
378 * debug.adb: Debug flag d.P to suppress length comparison optimization
379 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
380 comparison of Length by comparing First/Last instead.
382 2011-08-02 Matthew Heaney <heaney@adacore.com>
384 * a-cobove.ads: Code clean up.
386 2011-08-02 Vincent Celier <celier@adacore.com>
388 * adaint.c (file_names_case_sensitive_cache): New static int.
389 (__gnat_get_file_names_case_sensitive): Cache the return value in
390 file_names_case_sensitive_cache at the first invocation, to avoid
391 multiple calls to getenv.
393 2011-08-02 Bob Duff <duff@adacore.com>
395 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
397 2011-08-02 Yannick Moy <moy@adacore.com>
399 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
400 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
401 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
402 indicate that we are in a precondition or postcondition. This is used in
403 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
404 decide whether to flag the spec or body of the current subprogram as
407 2011-08-02 Fabien Chouteau <chouteau@adacore.com>
409 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
411 * a-extiin.ads: New file.
413 2011-08-02 Bob Duff <duff@adacore.com>
415 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
416 now raises Name_Error instead of Use_Error in certain cases. The other
417 parts of this AI were already implemented properly.
419 2011-08-02 Vincent Celier <celier@adacore.com>
421 * link.c: Only import "auto-host.h" when building the gnattools.
423 2011-08-02 Yannick Moy <moy@adacore.com>
425 * sem_util.adb: Inter-unit inlining does not work for a subprogram
426 which calls a local subprogram, so extract subprogram
427 from Mark_Non_ALFA_Subprogram_Body.
429 2011-08-02 Javier Miranda <miranda@adacore.com>
432 (Extract_Dispatching_Call): If the type of the dispatching object is an
433 access type then return an explicit dereference in the Object out-mode
436 2011-08-02 Gary Dismukes <dismukes@adacore.com>
438 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
439 compatibility checks for all indexes of an array subtype, not just the
440 first. Reset Has_Dynamic_Range_Check on the subtype before each
441 potential check to ensure that Insert_Range_Checks will not elide any
442 of the dynamic checks.
444 2011-08-02 Yannick Moy <moy@adacore.com>
446 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
447 SPARK restriction at parsing time.
448 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
449 directive only if the SPARK restriction is set for this unit.
451 2011-08-02 Yannick Moy <moy@adacore.com>
453 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
454 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
455 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
456 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
457 Mark_Non_ALFA_Subprogram_Body.
458 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
461 2011-08-02 Yannick Moy <moy@adacore.com>
463 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
466 2011-08-02 Robert Dewar <dewar@adacore.com>
468 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
469 exp_ch3.adb: Minor reformatting.
471 2011-08-02 Emmanuel Briot <briot@adacore.com>
473 * adaint.c (__gnat_locate_exec_on_path): only returns executable
474 files, not any regular file.
475 (__gnat_locate_file_with_predicate): new subprogram.
477 2011-08-02 Yannick Moy <moy@adacore.com>
479 * sinfo.adb, sinfo.ads: Restrict the use of flags
480 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
481 nodes, plus N_Subtype_Declaration for the 2nd one.
483 2011-08-02 Sergey Rybin <rybin@adacore.com>
485 * gnat_rm.texi: Ramification of pragma Eliminate documentation
486 - fix bugs in the description of Source_Trace;
487 - get rid of UNIT_NAME;
489 2011-08-02 Javier Miranda <miranda@adacore.com>
492 (Build_Dispatching_Requeue): Adding support for VM targets
493 since we cannot directly reference the Tag entity.
494 * exp_sel.adb (Build_K): Adding support for VM targets.
495 (Build_S_Assignment): Adding support for VM targets.
497 (Default_Prim_Op_Position): In VM targets do not restrict availability
498 of predefined interface primitives to compiling in Ada 2005 mode.
499 (Is_Predefined_Interface_Primitive): In VM targets this service is not
500 restricted to compiling in Ada 2005 mode.
501 (Make_VM_TSD): Generate code that declares and initializes the OSD
502 record. Needed to support dispatching calls through synchronized
505 (Make_Predefined_Primitive_Specs): Enable generation of predefined
506 primitives associated with synchronized interfaces.
507 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
508 primitives associated with synchronized interfaces.
510 2011-08-02 Yannick Moy <moy@adacore.com>
512 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
513 statements hidden in SPARK if preceded by the HIDE directive
514 (Parse_Exception_Handlers): mark each exception handler in a sequence of
515 exception handlers as hidden in SPARK if preceded by the HIDE directive
516 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
517 if starting with the HIDE directive
518 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
519 starting with the HIDE directive; mark the declarations in a private
520 part as hidden in SPARK if the private part starts with the HIDE
522 * restrict.adb, restrict.ads
523 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
524 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
525 argument node belongs to a part which is hidden in SPARK
526 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
527 parts in SPARK; protect the possibly costly call to
528 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
529 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
530 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
531 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
533 (Scan): recognize special comment starting with '#' and followed by
534 SPARK keyword "hide" as a HIDE directive.
536 2011-08-02 Yannick Moy <moy@adacore.com>
538 * types.ads, erroutc.ads: Minor reformatting.
540 2011-08-02 Vincent Celier <celier@adacore.com>
542 * link.c: Add response file support for cross platforms.
544 2011-08-02 Ed Schonberg <schonberg@adacore.com>
546 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
547 in an association, set parent field of copy before partial analysis.
548 * sem_res.adb (Resolve_Slice): create reference to itype only when
549 expansion is enabled.
551 2011-08-02 Yannick Moy <moy@adacore.com>
553 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
554 for new flag denoting which subprogram bodies are in ALFA
555 * restrict.adb, sem_ch7.adb: Update comment
556 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
557 sem_ch9.adb, sem_res.adb: Add calls to
558 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
559 * sem_ch6.adb (Analyze_Function_Return): add calls to
560 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
561 middle of the body, and extended return.
562 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
563 False when missing return.
564 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
565 to True for subprograms whose spec is in ALFA. Remove later on the flag
566 on the entity used for a subprogram body when there exists a separate
568 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
569 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
570 False, otherwise do nothing.
572 2011-08-02 Robert Dewar <dewar@adacore.com>
574 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
576 2011-08-02 Yannick Moy <moy@adacore.com>
578 * sem_ch4.ads: minor formatting.
580 2011-08-02 Yannick Moy <moy@adacore.com>
582 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
583 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
584 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
585 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
586 opt.ads: cleanup of SPARK mode
588 2011-08-02 Yannick Moy <moy@adacore.com>
590 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
592 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
593 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
595 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
596 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
597 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
598 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
600 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
602 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
603 functions whose return type is not in ALFA.
604 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
606 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
607 parameter's type is not in ALFA.
608 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
611 2011-08-02 Ed Schonberg <schonberg@adacore.com>
613 * sem_ch6 (Analyze_Expression_Function): treat the function as
614 Inline_Always, and introduce a subprogram declaration for it when it is
616 * inline.adb (Add_Inlined_Body): recognize bodies that come from
617 expression functions, so that the back-end can determine whether they
618 can in fact be inlined.
619 * sem_util.adb (Is_Expression_Function): predicate to determine whether
620 a function body comes from an expression function.
622 2011-08-02 Gary Dismukes <dismukes@adacore.com>
624 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
625 null exclusions to test Can_Never_Be_Null on the anonymous access types
626 of the formals rather than testing the formals themselves. Exclude this
627 check in cases where the Old_Formal is marked as a controlling formal,
628 to avoid issuing spurious errors for bodies completing dispatching
629 operations (due to the flag not getting set on controlling access
630 formals in body specs).
631 (Find_Corresponding_Spec): When checking full and subtype conformance of
632 subprogram bodies in instances, pass Designated and E in that order, for
633 consistency with the expected order of the formals (New_Id followed by
636 2011-08-02 Robert Dewar <dewar@adacore.com>
638 * sem_ch8.adb: Minor reformatting.
640 2011-08-02 Ed Schonberg <schonberg@adacore.com>
642 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
643 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
644 primitive operations of class-wide actuals.
646 2011-08-02 Javier Miranda <miranda@adacore.com>
648 * exp_atag.ads, exp_atag.adb
649 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
650 since its value is implicitly passed in argument Typ.
651 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
652 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
653 Build_Common_Dispatching_Select_Statements.
655 2011-08-02 Robert Dewar <dewar@adacore.com>
657 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
658 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
661 2011-08-02 Robert Dewar <dewar@adacore.com>
663 * sem_res.adb: Minor reformatting.
664 * sem_prag.adb: Minor reformatting.
666 2011-08-02 Javier Miranda <miranda@adacore.com>
668 * exp_atag.adb, exp_atags.ads
669 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
670 by the tagged type Entity. Required to use this routine in the VM
671 targets since we do not have available the Tag entity in the VM
674 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
675 Ada.Tags has not been previously loaded.
677 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
678 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
680 (Enclosing_Dynamic_Scope): Add missing support to handle the full
681 view of enclosing scopes. Required to handle enclosing scopes that
682 are synchronized types whose full view is a task type.
684 (Build_VM_TSDs): Minor code improvement to avoid generating and
685 analyzing lists with empty nodes.
686 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
687 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
688 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
689 (Make_Disp_Timed_Select_Body): Add support for VM targets.
690 (Make_Select_Specific_Data_Table): Add support for VM targets.
691 (Make_VM_TSD): Generate code to initialize the SSD structure of
694 2011-08-02 Yannick Moy <moy@adacore.com>
696 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
697 cross-references section in ALI.
698 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
699 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
701 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
702 subprogram or package entity of a node
703 (Is_Local_Reference_Type): new function returns True for references
704 selected in local cross-references.
705 (Lt): function extracted from Lt in Output_References
706 (Write_Entity_Name): function extracted from Output_References
707 (Generate_Definition): generate reference with type 'D' for definition
708 of objects (object declaration and parameter specification), with
709 appropriate locations and units, for use in local cross-references.
710 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
711 references of type 'I' for initialization in object definition.
712 (Output_References): move part of function Lt and procedure
713 Write_Entity_Name outside of the body. Ignore references of types 'D'
714 and 'I' introduced for local cross-references.
715 (Output_Local_References): new procedure to output the local
716 cross-references sections.
717 (Lref_Entity_Status): new array defining whether an entity is a local
718 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
719 with 'I' type when initialization expression is present.
720 * get_scos.adb, get_scos.ads: Correct comments and typos
722 2011-08-02 Javier Miranda <miranda@adacore.com>
724 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
726 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
728 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
731 2011-08-02 Vincent Celier <celier@adacore.com>
733 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
734 (No_Space_Img): New function
735 (Find_Excluded_Sources): When reading from a file, record the file name
736 and the line number for each excluded source.
737 (Mark_Excluded_Sources): When reporting an error, if the excluded
738 sources were read from a file, include file name and line number in
741 2011-08-02 Ed Schonberg <schonberg@adacore.com>
743 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
745 2011-08-02 Robert Dewar <dewar@adacore.com>
747 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
749 2011-08-02 Javier Miranda <miranda@adacore.com>
751 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
752 generation of TSDs to the DOTNET compiler.
753 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
754 generation of TSDs to the DOTNET compiler.
756 2011-08-02 Javier Miranda <miranda@adacore.com>
758 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
759 record of all the tagged types declared inside library level package
760 declarations, library level package bodies or library level subprograms.
761 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
762 associated with a given tagged type.
763 (Build_VM_TSDs): New subprogram.
764 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
765 compilation units that are subprograms.
766 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
767 compilation units that are package bodies.
768 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
769 units that are a package declaration or a package instantiation.
770 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
771 reorganization to improve the error generated by the frontend when the
772 function Ada.Tags.Secondary_Tag is not available.
773 * rtsfind.ads (RE_Register_TSD): New runtime entity.
774 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
776 2011-08-02 Javier Miranda <miranda@adacore.com>
778 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
780 2011-08-02 Robert Dewar <dewar@adacore.com>
782 * s-imenne.ads: Minor reformatting.
784 2011-08-02 Robert Dewar <dewar@adacore.com>
786 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
787 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
788 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
790 2011-08-02 Robert Dewar <dewar@adacore.com>
792 * einfo.ads (Materialize_Entity): Document this is only for renamings
793 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
794 required debug information in the case where we transform the object
795 declaration into a renaming declaration.
796 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
798 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
801 2011-08-02 Robert Dewar <dewar@adacore.com>
803 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
805 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
806 Suppress_Initialization/Initialization_Suppressed.
807 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
808 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
809 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
810 * sem_prag.adb: New processing for pragma Suppress_Initialization.
812 2011-08-02 Robert Dewar <dewar@adacore.com>
814 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
817 2011-08-02 Ed Schonberg <schonberg@adacore.com>
819 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
820 only have inheritable classwide pre/postconditions.
822 2011-08-02 Javier Miranda <miranda@adacore.com>
824 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
825 * rtsfind.ads (RE_Check_TSD): New runtime entity.
826 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
827 checks if the external tag of a type is the same as the external tag
828 of some other declaration.
830 2011-08-02 Thomas Quinot <quinot@adacore.com>
832 * s-taskin.ads: Minor reformatting.
834 2011-08-02 Emmanuel Briot <briot@adacore.com>
836 * g-comlin.adb (Display_Help): swap the order in which it prints the
837 short help and the general usage.
839 2011-08-02 Ed Schonberg <schonberg@adacore.com>
841 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
842 the aspect declarations and attach them to the generic copy for
844 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
845 declarations of the generic tree to the new subprogram declarations.
846 * sem_attr.adb (Check_Precondition_Postcondition): recognize
847 conditions that apply to a subprogram instance.
849 2011-08-02 Robert Dewar <dewar@adacore.com>
851 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
853 2011-08-02 Ed Schonberg <schonberg@adacore.com>
855 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
856 private type with a tagged full view is not derived in the immediate
857 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
859 2011-08-02 Robert Dewar <dewar@adacore.com>
861 * exp_ch4.adb: Minor reformatting.
863 2011-08-02 Ed Schonberg <schonberg@adacore.com>
865 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
866 Ada2012 iterator, the loop will be rewritten during expansion into a
867 while loop with a cursor and an element declaration. Do not analyze the
868 body in this case, because if the container is for indefinite types the
869 actual subtype of the elements will only be determined when the cursor
870 declaration is analyzed.
872 2011-08-02 Arnaud Charlet <charlet@adacore.com>
874 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
875 size/alignment related attributes in CodePeer_Mode.
877 2011-08-02 Gary Dismukes <dismukes@adacore.com>
879 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
880 Prepend_Element, since this can result in the operation getting the
881 wrong slot in the full type's dispatch table if the full type has
882 inherited operations. The incomplete type's operation will get added
883 to the proper position in the full type's primitives
884 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
885 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
886 dispatching operations, since there are cases where nonprimitive
887 subprograms can get added to the list of incomplete dependents (such
888 as subprograms in nested packages).
889 * sem_ch6.adb (Process_Formals): First, remove test for being in a
890 private part when determining whether to add a primitive with a
891 parameter of a tagged incomplete type to the Private_Dependents list.
892 Such primitives can also occur in the visible part, and should not have
893 been excluded from being private dependents.
894 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
895 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
896 list of a Taft-amendment incomplete type is a primitive before issuing
897 an error that the full type must appear in the same unit. There are
898 cases where nonprimitives can be in the list (such as subprograms in
900 * sem_disp.adb (Derives_From): Use correct condition for checking that
901 a formal's type is derived from the type of the corresponding formal in
902 the parent subprogram (the condition was completely wrong). Add
903 checking that was missing for controlling result types being derived
904 from the result type of the parent operation.
906 2011-08-02 Yannick Moy <moy@adacore.com>
908 * errout.adb (First_Node): minor renaming
909 * restrict.adb (Check_Formal_Restriction): put restriction warning on
912 2011-08-02 Yannick Moy <moy@adacore.com>
914 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
915 before accessing operands.
916 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
917 decide whether an initialization expression respects SPARK rules, as
918 the plain node is the expanded one. This allows for more valid warnings
920 * gnat_rm.texi: Minor update.
922 2011-08-02 Arnaud Charlet <charlet@adacore.com>
924 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
927 2011-08-02 Robert Dewar <dewar@adacore.com>
929 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
931 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
933 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
934 loop statements and the element renaming declaration with a block when
935 the element type is controlled.
937 2011-08-02 Yannick Moy <moy@adacore.com>
939 * sinfo.ads: Minor formatting.
941 2011-08-02 Ed Schonberg <schonberg@adacore.com>
943 * sem_aggr.adb (Add_Association): if the association has a box and no
944 expression, use the Sloc of the aggregate itself for the new
946 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
949 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
951 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
952 When a container is provided via a function call, generate a renaming
953 of the function result. This avoids the creation of a transient scope
954 and the premature finalization of the container.
955 * exp_ch7.adb (Is_Container_Cursor): Removed.
956 (Wrap_Transient_Declaration): Remove the supression of the finalization
957 of the list controller when the declaration denotes a container cursor,
960 2011-08-02 Yannick Moy <moy@adacore.com>
962 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
963 node is from source, instead of the original node being from source.
965 (Resolve_Array_Aggregate): refine the check for a static expression, to
966 recognize also static ranges
967 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
968 Array_Type_Declaration): postpone the test for the type being a subtype
969 mark after the type has been resolved, so that component-selection and
970 expanded-name are discriminated.
971 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
972 to distinguish the case of an iteration scheme, so that an error is
973 issed on a non-static range in SPARK except in an iteration scheme.
974 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
976 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
977 user-defined operators so that they are allowed in renaming
979 (Find_Selected_Component): refine the check for prefixing of operators
980 so that they are allowed in renaming. Move the checks for restrictions
981 on selector name after analysis discriminated between
982 component-selection and expanded-name.
983 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
984 concatenation argument of string type if it is static.
985 * sem_util.adb, sem_util.ads
986 (Check_Later_Vs_Basic_Declarations): add a new function
987 Is_Later_Declarative_Item to decice which declarations are allowed as
988 later items, in the two different modes Ada 83 and SPARK. In the SPARK
989 mode, add that renamings are considered as later items.
990 (Enclosing_Package): new function to return the enclosing package
991 (Enter_Name): correct the rule for homonyms in SPARK
992 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
993 from source (result of expansion) to avoid issuing wrong warnings.
995 2011-08-02 Ed Schonberg <schonberg@adacore.com>
997 * errout.adb: On anything but an expression First_Node returns its
1000 2011-08-02 Pascal Obry <obry@adacore.com>
1002 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
1004 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1006 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
1007 Set the associated loop as the related expression of internally
1009 * exp_ch7.adb (Is_Container_Cursor): New routine.
1010 (Wrap_Transient_Declaration): Supress the finalization of the list
1011 controller when the declaration denotes a container cursor.
1013 2011-08-02 Yannick Moy <moy@adacore.com>
1015 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
1017 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
1018 expression is a simple expression. This check cannot be performed in
1019 the semantics, so just drop it.
1020 (P_Index_Or_Discriminant_Constraint): move check that the index or
1021 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
1022 semantics. Other cases were previously checked in the semantics.
1023 * par-ch4.adb (P_Name): move checks that a selector name is not
1024 character literal or an operator symbol to Find_Selected_Component in
1026 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
1027 declarations are not placed after later declarations in a separate
1028 procedure in Sem_Util (possibly not the best choice?), to be used both
1029 during parsing, for Ada 83 mode, and during semantic analysis, for
1031 * par-endh.adb (Check_End): move check that end label is not missing
1032 to Process_End_Label in the semantics
1033 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
1034 the special case for SPARK restriction
1035 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
1036 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
1037 parameter Force to issue the error message even on internal node (used
1038 for generated end label). Call Check_Restriction to check when an error
1039 must be issued. In SPARK mode, issue an error message even if the
1040 restriction is not set.
1041 (Check_Restriction): new procedure with an additional out parameter to
1042 inform the caller that a message has been issued
1043 * sem_aggr.adb: Minor modification of message
1044 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
1045 instead of issuing an error message directly
1046 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
1047 declarations are not placed after later declarations, by calling
1048 Check_Later_Vs_Basic_Declarations
1049 (Analyze_Subtype_Declaration): move here the check that an index or
1050 discriminant constraint must be a subtype mark. Change the check that
1051 a subtype of String must start at one so that it works on subtype marks.
1052 * sem_ch4.adb (Analyze_Call): move here the check that a named
1053 association cannot follow a positional one in a call
1054 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
1055 instead of issuing an error message directly
1056 * sem_ch8.adb (Find_Selected_Component): move here the check that a
1057 selector name is not a character literal or an operator symbol. Move
1058 here the check that the prefix of an expanded name cannot be a
1059 subprogram or a loop statement.
1060 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
1061 procedure called from parsing and semantics to check that basic
1062 declarations are not placed after later declarations
1063 (Process_End_Label): move here the check that end label is not missing
1065 2011-08-02 Arnaud Charlet <charlet@adacore.com>
1067 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
1068 representation clause in codepeer mode, since it confuses CodePeer and
1069 does not bring useful info.
1071 2011-08-02 Ed Falis <falis@adacore.com>
1073 * init.c: initialize fp hw on MILS.
1075 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1077 * errout.adb (First_Node): for bodies, return the node itself (small
1078 optimization). For other nodes, do not check source_unit if the node
1079 comes from Standard.
1081 2011-08-02 Robert Dewar <dewar@adacore.com>
1083 * exp_ch3.adb: Minor comment additions.
1084 * sem_ch13.adb: Minor reformatting.
1086 2011-08-02 Pascal Obry <obry@adacore.com>
1088 * make.adb, makeutl.adb: Removes some superfluous directory separator.
1090 2011-08-02 Robert Dewar <dewar@adacore.com>
1092 * sem_attr.adb: Minor reformatting.
1094 2011-08-02 Robert Dewar <dewar@adacore.com>
1096 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
1097 (Has_Default_Component_Value): Removed
1098 * einfo.ads Comment updates
1099 (Has_Default_Aspect): Replaces Has_Default_Value
1100 (Has_Default_Component_Value): Removed
1102 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
1104 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
1105 (Get_Simple_Init_Val): Handle Default_Value aspect
1106 (Needs_Simple_Initialization): Handle Default_Value aspect
1107 * exp_ch3.ads: Needs_Simple_Initialization
1108 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
1109 * par-prag.adb (Pragma_Default[_Component]Value) Removed
1111 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
1112 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
1113 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
1115 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1117 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
1118 package containing iteration primitives.
1119 exp_ch5.adb (Expand_Iterator_Loop): ditto.
1121 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1123 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
1124 "of", pre-analyze expression in case it is a function call with
1125 finalization actions that must be placed ahead of the loop.
1126 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
1127 on an Ada2012 iterator, insert them ahead of the rewritten loop.
1129 2011-08-02 Geert Bosch <bosch@adacore.com>
1131 * cstand.adb (Create_Float_Types): Only consider C's long double for
1132 Long_Long_Float, in addition to double.
1134 2011-08-02 Robert Dewar <dewar@adacore.com>
1136 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
1137 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
1138 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
1141 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1143 * sem_attr.adb: handle properly 'Result when it is a prefix of an
1146 2011-08-02 Javier Miranda <miranda@adacore.com>
1148 * einfo.ads, einfo.adb
1149 (Original_Access_Type): Move this attribute to Node26 since there was
1150 an undocumented use of Node21 in E_Access_Subprogram_Type entities
1151 which causes conflicts and breaks the generation of the .NET compiler.
1152 (Interface_Name): Add missing documentation on JGNAT only uses of
1155 2011-08-02 Geert Bosch <bosch@adacore.com>
1157 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
1158 (Find_Back_End_Float_Type): Likewise
1159 (Create_Back_End_Float_Types): Likewise
1160 (Create_Float_Types): Likewise
1161 (Register_Float_Type): Likewise
1162 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
1163 Nlist and split out type selection in new local Find_Base_Type function.
1164 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
1166 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
1168 2011-08-02 Robert Dewar <dewar@adacore.com>
1170 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
1172 * opt.ads: Minor comment change.
1173 * sem_ch12.adb: Minor code reorganization.
1175 2011-08-02 Gary Dismukes <dismukes@adacore.com>
1177 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
1178 subtype's list of rep items to the list on the full subtype in the case
1179 where the lists are the same.
1181 2011-08-02 Geert Bosch <bosch@adacore.com>
1183 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
1184 using the one from System.Strings, which also deallocates all strings.
1186 2011-08-02 Geert Bosch <bosch@adacore.com>
1188 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
1190 * gcc-interface/Make-lang.in: Update dependencies.
1192 2011-08-02 Olivier Hainque <hainque@adacore.com>
1194 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
1197 2011-08-02 Javier Miranda <miranda@adacore.com>
1199 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
1200 associated with anonymous access to subprograms.
1202 2011-08-02 Geert Bosch <bosch@adacore.com>
1205 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
1206 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
1207 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
1208 (Add_Symbol_Definition): Move to switch-c.adb
1209 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
1210 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
1211 (Add_Symbol_Definition): Move to switch-c.adb.
1212 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
1214 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
1216 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
1217 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
1219 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
1220 (Add_Symbol_Definition): Moved from Prepcomp.
1221 * switch-c.ads: Update copyright notice. Use String_List instead of
1222 Argument_List, removing dependency on System.OS_Lib.
1224 2011-08-02 Yannick Moy <moy@adacore.com>
1226 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
1227 mode on initialization expression which does not respect SPARK
1229 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
1230 if the tree referenced by its argument represents an initialization
1231 expression in SPARK, suitable for initializing an object in an object
1234 2011-08-02 Javier Miranda <miranda@adacore.com>
1236 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
1237 internally generated access to subprogram with its associated protected
1239 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
1241 2011-08-02 Geert Bosch <bosch@adacore.com>
1243 * cstand.adb (Register_Float_Type): Print information about type to
1244 register, if the Debug_Flag_Dot_B is set.
1245 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
1246 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
1247 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
1248 with a requested precision of more than Max_Digits digits and no more
1249 than Max_Base_Digits digits, if a range specification is present and the
1250 Predefined_Float_Types list has a suitable type to derive from.
1251 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
1252 case of type completion with pragma Import
1254 (Process_Import_Predefined_Type): Processing to complete a type
1255 with pragma Import. Currently supports floating point types only.
1256 (Set_Convention_From_Pragma): Do nothing without underlying type.
1257 (Process_Convention): Guard against absence of underlying type,
1258 which may happen when importing incomplete types.
1259 (Process_Import_Or_Interface): Handle case of importing predefined
1260 types. Tweak error message.
1262 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1264 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
1265 functions to previous change. Reorganize code slightly.
1267 2011-08-02 Geert Bosch <bosch@adacore.com>
1269 * back_end.ads (Register_Type_Proc): New call back procedure type for
1270 allowing the back end to provide information about available types.
1271 (Register_Back_End_Types): New procedure to register back end types.
1272 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
1274 * cstand.adb (Back_End_Float_Types): New list for floating point types
1275 supported by the back end.
1276 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
1277 (Copy_Float_Type): New procedure to make new copies of predefined types.
1278 (Register_Float_Type): New call back procedure to populate the BEFT list
1279 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
1280 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
1281 (Create_Float_Types): New procedure to create entities for floating
1282 point types predefined in Standard, and put these and any remaining
1283 BEFTs on the Predefined_Float_Types list.
1284 * stand.ads (Predefined_Float_Types): New list for predefined floating
1285 point types that do not have declarations in package Standard.
1287 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1289 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
1290 entity node for the unit containing the parameter.
1291 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
1292 (Add_Inlined_Subprogram): Likewise.
1293 * gcc-interface/Make-lang.in: Update dependencies.
1295 2011-08-02 Thomas Quinot <quinot@adacore.com>
1297 * s-stusta.adb (Print): Make sure Pos is always initialized to a
1300 2011-08-02 Geert Bosch <bosch@adacore.com>
1302 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
1304 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1306 * sem_type.adb (Covers): Move trivial case to the top and reuse the
1307 computed value of Base_Type.
1309 2011-08-02 Yannick Moy <moy@adacore.com>
1311 * restrict.adb (Check_Restriction): issue an error for any use of
1312 class-wide, even if the No_Dispatch restriction is not set.
1313 * sem_aggr.adb: Correct typos in comments and messages in formal mode
1314 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
1315 when completing a private extension, the type named in the private part
1316 is not the same as that named in the visible part.
1317 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
1318 of an inherited primitive operations of a tagged type or type extension
1319 that returns the tagged type.
1320 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
1321 function which returns True for an implicit operation inherited by the
1322 derived type declaration for the argument type.
1323 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
1326 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1328 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
1329 Process_Bounds, to perform analysis with expansion of a range or an
1330 expression that is the iteration scheme for a loop.
1331 (Analyze_Iterator_Specification): If domain of iteration is given by a
1332 function call with a controlled result, as is the case if call returns
1333 a predefined container, ensure that finalization actions are properly
1335 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
1337 2011-08-02 Javier Miranda <miranda@adacore.com>
1339 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
1340 * gcc-interface/Make-lang.in: Update dependencies.
1342 2011-08-02 Javier Miranda <miranda@adacore.com>
1344 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
1345 determine if the analysis is performed using N or Original_Node (N).
1346 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
1347 functionality of routine Is_Variable avoids code duplication.
1348 * checks.adb (Determine_Range): Handle temporaries generated by
1349 Remove_Side_Effects.
1351 2011-08-02 Javier Miranda <miranda@adacore.com>
1353 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
1354 expansion of the condition. Required since the previous analysis was
1355 done with expansion disabled (see Resolve_Quantified_Expression) and
1356 hence checks were not inserted and record comparisons have not been
1359 2011-08-02 Ed Falis <falis@adacore.com>
1361 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
1364 2011-08-02 Bob Duff <duff@adacore.com>
1366 * opt.ads: Minor comment fix.
1368 2011-08-02 Bob Duff <duff@adacore.com>
1370 * sem_ch12.adb (Analyze_Package_Instantiation,
1371 Analyze_Subprogram_Instantiation): Turn off style checking while
1372 analyzing an instance. Whatever style checks that apply to the generic
1373 unit should apply, so it makes no sense to apply them in an instance.
1374 This was causing trouble when compiling an instance of a runtime
1375 unit that violates the -gnatyO switch.
1376 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
1377 one of the two case statements, causing spurious errors.
1379 2011-08-02 Robert Dewar <dewar@adacore.com>
1381 * uname.adb: Minor reformatting.
1382 * gnatcmd.adb: Minor reformatting.
1383 * exp_attr.adb: Minor reformatting.
1385 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1387 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
1388 No_Dispatching_Calls, do not look for the Assign primitive, because
1389 predefined primitives are not created in this case.
1391 2011-08-02 Bob Duff <duff@adacore.com>
1393 * stylesw.ads: Minor comment fixes.
1395 2011-08-02 Robert Dewar <dewar@adacore.com>
1397 * freeze.adb (Add_To_Result): New procedure.
1399 2011-08-02 Jose Ruiz <ruiz@adacore.com>
1401 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
1402 time, if the specific run-time routines for handling streams of strings
1403 are not available, use the default mechanism.
1405 2011-08-02 Arnaud Charlet <charlet@adacore.com>
1407 * s-regpat.ads: Fix typo.
1409 2011-08-02 Vincent Celier <celier@adacore.com>
1411 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
1412 not null, call it to create the in memory config project file without
1413 parsing an existing default config project file.
1415 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1417 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
1419 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1421 * sem_elim.adb: an abstract subprogram does not need an eliminate
1422 pragma for its descendant to be eliminable.
1424 2011-08-02 Ed Falis <falis@adacore.com>
1426 * init.c: revert to handling before previous checkin for VxWorks
1427 * s-intman-vxworks.adb: delete unnecessary declarations related to
1428 using Ada interrupt facilities for handling signals.
1429 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
1430 * s-intman-vxworks.ads: Import __gnat_install_handler as
1431 Initialize_Interrupts.
1432 * s-taprop-vxworks.adb: Delete Signal_Mask.
1433 (Abort_Handler): change construction of mask to unblock exception
1436 2011-08-02 Jerome Guitton <guitton@adacore.com>
1438 * a-except-2005.adb (Raise_From_Signal_Handler): Call
1439 Debug_Raise_Exception before propagation starts.
1441 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1443 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
1444 to Restriction_Check_Required.
1445 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
1446 * sem_res.adb (Resolve_Call): Likewise.
1447 * sem_attr.adb (Check_Stream_Attribute): Likewise.
1449 2011-08-02 Bob Duff <duff@adacore.com>
1451 * stylesw.ads: Update comment.
1452 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
1453 * errout.ads: Remove obsolete comment.
1455 2011-08-02 Javier Miranda <miranda@adacore.com>
1457 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
1458 (Set_Is_Safe_To_Reevaluate): new procedure.
1459 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
1460 assignment is allowed on safe-to-reevaluate variables.
1461 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
1462 temporary created to remove side effects in expressions that use
1463 the secondary stack as safe-to-reevaluate.
1464 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
1465 variables that are not true constants.
1467 2011-08-02 Robert Dewar <dewar@adacore.com>
1469 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
1470 sem_res.adb, sem_ch6.adb: Minor reformatting.
1472 2011-08-02 Jerome Guitton <guitton@adacore.com>
1474 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
1476 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1478 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
1479 not set Overridden_Operation if subprogram is an initialization
1482 2011-08-02 Yannick Moy <moy@adacore.com>
1484 * par-ch6.adb: Correct obsolete name in comments
1485 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
1486 which takes two message arguments (existing function takes one), with
1487 second message used for continuation.
1488 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
1489 block statements that originate from a source block statement, not
1490 generated block statements
1491 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
1492 symmetry with procedure case
1493 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
1494 function to issue an error in formal mode if a package specification
1495 contains more than one tagged type or type extension.
1496 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
1497 parameters matching formals of tagged types are objects (or ancestor
1498 type conversions of objects), not general expressions. Issue an error
1499 on view conversions that are not involving ancestor conversion of an
1501 (Resolve_Type_Conversion): in formal mode, issue an error on the
1502 operand of an ancestor type conversion which is not an object
1503 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
1504 procedure so that it works also for actuals of function calls
1505 (Is_Actual_Tagged_Parameter): new function which determines if its
1506 argument is an actual parameter of a formal of tagged type in a
1508 (Is_SPARK_Object_Reference): new function which determines if the tree
1509 referenced by its argument represents an object in SPARK
1511 2011-08-02 Robert Dewar <dewar@adacore.com>
1513 * sem_ch3.adb: Minor reformatting
1514 Minor comment addition
1515 Minor error msg text change
1517 2011-08-02 Javier Miranda <miranda@adacore.com>
1519 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
1520 function. Used to be more precise when we generate a variable plus one
1521 assignment to remove side effects in the evaluation of the Bound
1523 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
1524 of the bound expression to force its re-analysis and thus expand the
1525 associated transient scope (if required). Code cleanup replacing the
1526 previous code that declared the constant entity by an invocation to
1527 routine Force_Evaluation which centralizes this work in the frontend.
1529 2011-08-02 Robert Dewar <dewar@adacore.com>
1531 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
1532 (Base_Type): Now uses improved Is_Base_Type function
1533 * einfo.ads (Base_Type): Inline this function
1535 2011-08-02 Robert Dewar <dewar@adacore.com>
1537 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
1538 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
1540 2011-08-02 Arnaud Charlet <charlet@adacore.com>
1542 * gcc-interface/Make-lang.in: Update dependencies.
1543 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
1546 2011-08-02 Yannick Moy <moy@adacore.com>
1548 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
1549 non-simple expression used in delta constraint
1550 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
1551 index constraint which is not a subtype mark
1552 * par.adb: With and use Restrict
1553 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
1554 mode on component type which is not a subtype mark and default
1555 expression on component
1556 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
1557 of string which does not have a lower index bound equal to 1
1558 (Array_Type_Declaration): issue an error in formal mode on index or
1559 component type which is not a subtype mark, and on aliased keyword on
1561 (Derived_Type_Declaration): issue an error in formal mode on interface,
1562 limited or abstract type
1563 (Record_Type_Declaration): issue an error in formal mode on interface
1564 (Record_Type_Definition): issue an error in formal mode on tagged types
1565 and type extensions not declared in the specification of a library unit
1566 package; on null non-tagged record; on variant part
1568 2011-08-02 Vincent Celier <celier@adacore.com>
1570 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
1571 not declared for qualified library project when Library_Name is not
1572 declared, but Library_Dir is.
1574 2011-08-02 Robert Dewar <dewar@adacore.com>
1576 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
1577 pragmas (affects aspects [Component_]Default_Value
1578 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
1579 component type for the resolution
1581 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1583 * einfo.adb (Base_Type): Tune implementation for speed.
1585 2011-08-02 Robert Dewar <dewar@adacore.com>
1587 * freeze.adb: Minor reformatting.
1589 2011-08-02 Thomas Quinot <quinot@adacore.com>
1591 * scos.ads: Update comments.
1593 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1595 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
1596 base type, because the parent may be a subtype of a private type whose
1597 convention is established in a private part.
1599 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1601 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
1602 statement in a block when the expansion of the return expression has
1603 created a finalization chain.
1604 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
1605 with the parent node.
1606 Add N_Extended_Return_Statement to handle the case where a transient
1607 object declaration appears in the Return_Object_Declarations list of
1608 an extended return statement.
1610 2011-08-02 Matthew Gingell <gingell@adacore.com>
1612 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
1613 unused parameter 'name'.
1615 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1617 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
1618 inherited operation, check whether its alias, which is the source
1619 operastion that it renames, has been marked eliminated.
1621 2011-08-02 Javier Miranda <miranda@adacore.com>
1623 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
1624 in-mode parameter whose type is an access type since it can be used to
1625 modify its designated object. Enforce code that handles as safe an
1626 access type that is not access-to-constant but it is the result of a
1627 previous removal of side-effects.
1628 (Remove_Side_Effects): Minor code reorganization of cases which require
1629 no action. Done to incorporate documentation on new cases uncovered
1630 working in this ticket: no action needed if this routine was invoked
1631 too early and the nodes are not yet decorated.
1632 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
1633 to routine Remove_Side_Effects by calls to Force_Evaluation since they
1634 were issued with actuals that are implicitly provided by
1637 2011-08-02 Robert Dewar <dewar@adacore.com>
1639 * sem_ch3.adb, sem_res.adb: Minor reformatting.
1641 2011-08-02 Yannick Moy <moy@adacore.com>
1643 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
1644 to issue an error in formal mode on attribute not supported in this mode
1645 (Analyze_Attribute): issue errors on standard attributes not supported
1647 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
1648 comment, and issue error in formal mode on modulus which is not a power
1650 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
1652 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
1654 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
1655 operator on modular type (except 'not').
1657 2011-08-02 Robert Dewar <dewar@adacore.com>
1659 * gnat_rm.texi: Minor reformatting.
1661 2011-08-02 Arnaud Charlet <charlet@adacore.com>
1663 * s-osinte-linux.ads: Minor comment update and reformatting.
1664 * i-cexten.ads: Make this unit pure, as for its parent.
1665 Will allow its usage in more contexts if needed.
1667 2011-08-02 Robert Dewar <dewar@adacore.com>
1669 * s-utf_32.ads: Minor comment fix.
1671 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1673 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
1674 operation of a tagged synchronized type, handle the case where the
1675 controlling argument is overloaded.
1677 2011-08-02 Yannick Moy <moy@adacore.com>
1679 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
1680 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
1681 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
1682 SPARK mode and formal verification mode on processing SPARK restriction
1683 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
1684 requiring consistency checking.
1686 2011-08-02 Robert Dewar <dewar@adacore.com>
1688 * sem_res.adb: Minor reformatting.
1690 2011-08-02 Robert Dewar <dewar@adacore.com>
1692 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
1693 a-cforse.ads: Remove unneeded with of Ada.Containers
1694 Remove commented out pragma Inline's
1695 Move specifications of new subprograms to the actual specs
1697 2011-08-02 Yannick Moy <moy@adacore.com>
1699 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
1700 a-cforse.ads: Update comments.
1702 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1704 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
1706 2011-08-02 Robert Dewar <dewar@adacore.com>
1708 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
1709 a-cforse.ads, a-cofove.ads: Minor reformatting.
1711 2011-08-02 Claire Dross <dross@adacore.com>
1713 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
1714 a-cofove.ads: Add comments.
1716 2011-08-02 Yannick Moy <moy@adacore.com>
1718 * gnat_rm.texi: Document formal containers.
1720 2011-08-02 Emmanuel Briot <briot@adacore.com>
1722 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
1725 2011-08-02 Robert Dewar <dewar@adacore.com>
1727 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
1730 2011-08-02 Robert Dewar <dewar@adacore.com>
1732 * aspects.adb: New aspects Default_Value and Default_Component_Value
1733 New format of Aspect_Names table checks for omitted entries
1734 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
1735 handling of boolean aspects for derived types.
1736 New aspects Default_Value and Default_Component_Value
1737 New format of Aspect_Names table checks for omitted entries
1738 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
1739 (Has_Default_Value): New flag
1740 (Has_Default_Component_Value): New flag
1741 (Has_Default_Value): New flag
1742 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
1744 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
1745 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
1746 Default_Value and Default_Component_Value
1747 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
1748 New aspects Default_Value and Default_Component_Value
1749 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
1750 * sprint.adb: Print N_Aspect_Specification node when called from gdb
1752 2011-08-02 Vincent Celier <celier@adacore.com>
1754 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
1755 inherit library kind.
1757 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1759 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
1762 2011-08-02 Robert Dewar <dewar@adacore.com>
1764 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
1766 2011-08-02 Yannick Moy <moy@adacore.com>
1768 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
1770 2011-08-02 Robert Dewar <dewar@adacore.com>
1772 * impunit.adb: Add comment.
1774 2011-08-02 Yannick Moy <moy@adacore.com>
1776 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
1777 qualification of aggregates in formal mode
1778 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
1780 (Resolve_Aggregate): complete the test that an aggregate is adequately
1781 qualified in formal mode
1783 2011-08-02 Pascal Obry <obry@adacore.com>
1785 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
1786 * mlib-prj.adb: Supress warning when compiling binder generated file.
1787 (Build_Library): Supress all warnings when compiling the binder
1790 2011-08-02 Yannick Moy <moy@adacore.com>
1792 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
1794 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
1795 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
1796 Add with/use clauses to make Check_Formal_Restriction visible
1798 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1800 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
1801 in-parameters when type of the generic formal is private in the generic
1802 spec and non-private in the body.
1804 2011-08-02 Claire Dross <dross@adacore.com>
1806 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
1807 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
1808 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
1809 * impunit.adb, Makefile.rtl: Take new files into account.
1811 2011-08-02 Robert Dewar <dewar@adacore.com>
1813 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
1814 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
1816 2011-08-02 Yannick Moy <moy@adacore.com>
1818 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
1820 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
1821 matching static array bounds, taking into account the special case of
1823 * sem_ch3.adb: Typo in comment.
1825 2011-08-02 Yannick Moy <moy@adacore.com>
1827 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
1828 which issues an error in formal mode if its argument node is originally
1830 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
1831 has a discriminant specification so that it does not include the case
1833 (Derived_Type_Declaration): move here the test that a derived type has a
1834 discriminant specification
1835 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
1836 first element of a component association before accessing its choices
1837 (presence of component association is not enough)
1838 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
1839 declaration is a library item before accessing the next element in a
1840 list, as library items are not member of lists
1841 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
1842 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
1843 Check_Formal_Restriction whenever possible.
1845 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1847 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
1848 reference when needed.
1850 2011-08-02 Bob Duff <duff@adacore.com>
1852 * gnat_ugn.texi: Fix typo.
1854 2011-08-02 Vincent Celier <celier@adacore.com>
1856 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
1857 archive file name. Do not use the full path name of archives for Open
1860 2011-08-02 Robert Dewar <dewar@adacore.com>
1862 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
1863 Analyze_Aspect_Specifications
1865 (Analyze_Aspect_Specifications): New handling for boolean aspects
1866 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
1867 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
1868 sequence for Analyze_Aspect_Specifications
1869 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
1870 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
1872 2011-08-02 Robert Dewar <dewar@adacore.com>
1874 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
1875 aspects, since these no longer exist.
1877 2011-08-02 Robert Dewar <dewar@adacore.com>
1879 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
1880 semicolon, do not try to see if there are aspects following it.
1881 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
1884 2011-08-02 Robert Dewar <dewar@adacore.com>
1886 * sem_ch8.adb, aspects.ads: Minor reformatting.
1888 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1890 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
1891 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
1893 (Analyze_Aspect_Specifications): ...here. Call above procedure.
1895 2011-08-02 Yannick Moy <moy@adacore.com>
1897 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
1898 mode on subprogram declaration outside of package specification, unless
1899 it is followed by a pragma Import
1900 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
1901 Access_Type_Declaration): issue error in formal mode on access type
1902 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
1904 (Analyze_Object_Declaration): issue error in formal mode on object
1905 declaration which does not respect SPARK restrictions
1906 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
1907 declaration which does not respect SPARK restrictions
1908 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
1909 error in formal mode on digits or delta constraint
1910 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
1911 decimal fixed point type
1912 (Derived_Type_Declaration): issue error in formal mode on derived type
1913 other than type extensions of tagged record types
1914 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
1915 with check on access definition
1916 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
1917 mode on protected definition.
1918 (Analyze_Task_Definition): issue error in formal mode on task definition
1920 2011-08-02 Robert Dewar <dewar@adacore.com>
1922 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
1924 2011-08-02 Javier Miranda <miranda@adacore.com>
1926 * sem_ch6.adb (Can_Override_Operator): New function.
1927 (Verify_Overriding_Indicator): Add missing code to check overriding
1928 indicator in operators. Fixes regression.
1929 (Check_Overriding_Indicator): Minor reformating after replacing the
1930 code that evaluates if the subprogram can override an operator by
1931 invocations to the above new function.
1933 (Write_Field26_Name): Add missing code to ensure that, following
1934 the documentation in einfo.ads, this field is not shown as attribute
1935 "Static_Initialization" on non-dispatching functions.
1937 2011-08-02 Jose Ruiz <ruiz@adacore.com>
1939 * sem_res.adb (Resolve_Call): A call to
1940 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
1941 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
1942 i.e., when the second parameter is of type Time_Span.
1944 2011-08-02 Vincent Celier <celier@adacore.com>
1946 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
1947 with an archive instead of -L<library dir> -l<library name>.
1949 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1951 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
1952 mark the base types In_Use in addition to making the operations
1955 2011-08-02 Ed Falis <falis@adacore.com>
1957 * init.c: add and setup __gnat_signal_mask for the exception signals
1958 * s-inmaop-vxworks.adb: new file.
1959 * s-intman-vxworks.adb: remove unnecessary initializations and
1961 * s-intman-vxworks.ads: remove unnecessary variable
1962 * s-taprop-vxworks.adb: simplify signal initialization
1964 2011-08-02 Robert Dewar <dewar@adacore.com>
1966 * sem_ch8.adb: Minor code reorganization, comment updates.
1968 2011-08-02 Robert Dewar <dewar@adacore.com>
1970 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
1971 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
1973 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
1974 (Matching_Static_Array_Bounds): Moved here from Sem_Res
1976 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1978 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
1979 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
1980 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
1981 use_type_clauses, to handle more efficiently use_type and use_all_type
1983 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
1984 Ada2012 Use_All_Type clause.
1985 (Use_Class_Wide_Operations): new procedure.
1987 2011-08-02 Robert Dewar <dewar@adacore.com>
1989 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
1990 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
1991 expression to expression function.
1993 2011-08-02 Ed Schonberg <schonberg@adacore.com>
1995 * sem_ch4.adb: transform simple Ada2012 membership into equality only
1996 if types are compatible.
1998 2011-08-02 Yannick Moy <moy@adacore.com>
2000 * sem_res.adb (Matching_Static_Array_Bounds): new function which
2001 returns True if its argument array types have same dimension and same
2002 static bounds at each index.
2003 (Resolve_Actuals): issue an error in formal mode on actuals passed as
2004 OUT or IN OUT paramaters which are not view conversions in SPARK.
2005 (Resolve_Arithmetic_Op): issue an error in formal mode on
2006 multiplication or division with operands of fixed point types which are
2007 not qualified or explicitly converted.
2008 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
2009 Boolean or array type (except String) operands.
2010 (Resolve_Equality_Op): issue an error in formal mode on equality
2011 operators for array types other than String with non-matching static
2013 (Resolve_Logical_Op): issue an error in formal mode on logical operators
2014 for array types with non-matching static bounds. Factorize the code in
2015 Matching_Static_Array_Bounds.
2016 (Resolve_Qualified_Expression): issue an error in formal mode on
2017 qualified expressions for array types with non-matching static bounds.
2018 (Resolve_Type_Conversion): issue an error in formal mode on type
2019 conversion for array types with non-matching static bounds
2021 2011-08-02 Robert Dewar <dewar@adacore.com>
2023 * par-ch10.adb: Minor code reorganization (use Nkind_In).
2025 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2027 * par-ch9.adb: save location of entry for proper error message.
2029 2011-08-02 Javier Miranda <miranda@adacore.com>
2031 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
2032 (Use_Full_View) which permits this routine to climb through the
2033 ancestors using the full-view of private parents.
2034 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
2035 Use_Full_View to true in calls to Is_Ancestor.
2036 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
2037 true in call to Is_Ancestor.
2038 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
2039 Use_Full_View to true in call to Is_Ancestor.
2040 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
2041 call to Is_Ancestor.
2042 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
2043 Use_Full_View to true in calls to Is_Ancestor.
2044 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
2045 Make_Select_Specific_Data_Table, Register_Primitive,
2046 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
2047 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
2048 to true in call to Is_Ancestor.
2049 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
2050 Use_Full_View to true in calls to Is_Ancestor.
2052 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
2053 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
2055 2011-08-02 Robert Dewar <dewar@adacore.com>
2057 * gnat_rm.texi: Minor reformatting.
2058 * sem_prag.adb: Minor reformatting.
2060 2011-08-02 Tristan Gingold <gingold@adacore.com>
2062 * vms_data.ads: Add VMS qualifier for -gnateP.
2064 2011-08-02 Robert Dewar <dewar@adacore.com>
2066 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
2067 * par-ch7.adb (P_Package): Proper placement of aspects for package
2069 * par-endh.adb (Check_End): Ad Is_Sloc parameter
2070 (End_Statements): Add Is_Sloc parameterr
2071 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
2072 (Check_End): Ad Is_Sloc parameter
2073 (End_Statements): Add Is_Sloc parameterr
2075 2011-08-02 Vincent Celier <celier@adacore.com>
2077 * ug_words: Add VMS qualifier equivalent to -gnateP:
2078 /SYMBOL_PREPROCESSING.
2080 2011-08-02 Jose Ruiz <ruiz@adacore.com>
2082 * gnat-style.texi: For hexadecimal numeric literals the typical
2083 grouping of digits is 4 to represent 2 bytes.
2084 A procedure spec which is split into several lines is indented two
2087 2011-08-02 Yannick Moy <moy@adacore.com>
2089 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
2090 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
2091 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
2093 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
2094 choice in array aggregate
2095 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
2097 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
2098 positional and named aggregate for record, or others in record
2099 aggregate, or multiple choice in record aggregate
2100 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
2101 array operands to logical operations AND, OR and XOR do not have the
2102 same static lower and higher bounds
2103 * sem_ch5.adb, sinfo.ads: Correct typos in comments
2105 2011-08-01 Robert Dewar <dewar@adacore.com>
2107 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
2108 Replaces Last_Source_Node_In_Sequence.
2109 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
2110 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
2111 parens and blank in string (this was inconsistently implemented).
2113 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
2114 blank in string (this was inconsistently implemented).
2116 (Set_Global_Switches): Set formal mode switches appropriately
2117 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
2119 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
2120 call Set_Error_Msg_Lang to set "spark" as language name.
2121 * par.adb: Remove unnecessary call to set formal language for errout
2122 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
2123 appropriately and call Set_Error_Msg_Lang to set "spark" as language
2125 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
2126 calls to it, moved after resolution so that types are known
2127 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
2128 result of concatenation is not of type String
2129 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
2130 concatenation is not properly restricted
2131 * gnat_rm.texi: Add doc on pragma Spark_95.
2132 * gcc-interface/Makefile.in: Remove obsolete target pairs for
2133 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
2134 * gcc-interface/Make-lang.in: Update dependencies.
2136 2011-08-01 Javier Miranda <miranda@adacore.com>
2138 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
2139 condition that detects if the overridden operation must replace an
2142 2011-08-01 Javier Miranda <miranda@adacore.com>
2144 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
2145 code declarations inserted by Insert_Actions in each alternative of the
2146 N_Case_Expression node.
2148 2011-08-01 Robert Dewar <dewar@adacore.com>
2150 * sem_ch6.adb: Minor code reorganization.
2151 * sem_util.adb: Minor reformatting.
2153 2011-08-01 Pascal Obry <obry@adacore.com>
2155 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
2156 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
2158 2011-08-01 Yannick Moy <moy@adacore.com>
2160 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
2161 literal or operator symbol which is prefixed
2162 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
2163 mode on access attributes.
2164 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
2165 that concatenation operands are properly restricted in formal mode
2166 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
2167 Analyze_Concatenation_Operand. Issue an error in formal mode if the
2168 result of the concatenation has a type different from String.
2169 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
2170 Analyze_Quantified_Expression, Analyze_Slice,
2171 Analyze_Null): issue an error in formal mode on unsupported constructs
2173 (Analyze_Block_Statement): only issue error on source block statement
2174 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
2175 function which returns the last node in a list of nodes for which
2176 Comes_From_Source returns True, if any
2177 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
2178 Last_Source_Node_In_Sequence
2179 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
2180 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
2181 mode on unsupported constructs
2182 * sem_ch9.adb Do not return after issuing error in formal mode, as the
2183 rest of the actions may be needed later on since the error is marked as
2185 * sinfo.ads: Typos in comments.
2187 2011-08-01 Pascal Obry <obry@adacore.com>
2189 * projects.texi: Minor editing.
2191 2011-08-01 Yannick Moy <moy@adacore.com>
2193 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
2194 insertion character ~~
2195 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
2196 (Set_Error_Msg_Lang): new procedure which fixes the language for use
2197 with insertion character ~~
2198 (Set_Msg_Text): treat insertion character ~~
2199 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
2200 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
2201 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
2202 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
2203 errors related to the formal language restriction not serious
2204 (insertion character |).
2205 * par.adb (Par): set formal language for error messages if needed
2206 * sem_ch6.adb (Check_Missing_Return): take into account possible
2207 generated statements at the end of the function
2208 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
2209 enumeration value to define a new pragma SPARK_95
2210 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
2211 SPARK_Version): new type and variables to store the SPARK version
2213 (SPARK_Mode): return True when SPARK_Version is set
2214 * par-prag.adb: Correct indentation
2215 (Prag): take Pragma_SPARK_95 into account
2216 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
2219 2011-08-01 Robert Dewar <dewar@adacore.com>
2221 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
2222 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
2223 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
2225 2011-08-01 Pascal Obry <obry@adacore.com>
2227 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
2228 Target_Name to Get_Path call.
2229 (Parse_Single_Project): Likewise.
2230 (Post_Parse_Context_Clause): Likewise.
2231 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
2232 Call Initialise_Project_Path with the proper Target_Name.
2233 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
2235 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
2236 with the proper Target_Name.
2237 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
2239 (Parse_Project_And_Apply_Config): Likewise.
2240 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
2241 This is fine as this part of the code is supporting only native
2243 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
2244 is fine as this part of the code is supporting only native compilation.
2246 2011-08-01 Yannick Moy <moy@adacore.com>
2248 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
2249 of homonym, unless the homonym is one of the cases allowed in SPARK
2250 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
2251 package declaration occurring after a body.
2253 2011-08-01 Robert Dewar <dewar@adacore.com>
2255 * checks.adb, exp_ch4.adb: Minor reformatting.
2257 2011-08-01 Javier Miranda <miranda@adacore.com>
2259 * einfo.ads (Access_Disp_Table): Fix documentation.
2260 (Dispatch_Table_Wrappers): Fix documentation.
2262 2011-08-01 Pascal Obry <obry@adacore.com>
2264 * prj-env.adb, prj-env.ads: Minor reformatting.
2266 2011-08-01 Yannick Moy <moy@adacore.com>
2268 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
2269 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
2270 procedures out of these packages.
2271 * errout.ads, errout.adb
2272 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
2273 procedures in of this package
2274 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
2275 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
2276 on misplaced later vs initial declarations, like in Ada 83
2277 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
2278 formal mode on attribute of private type whose full type declaration
2280 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
2281 package declaration inside a package specification
2282 (Analyze_Full_Type_Declaration): issue error in formal mode on
2283 controlled type or discriminant type
2284 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
2285 user-defined operator means that it should come from the source
2286 (New_Overloaded_Entity): issue error in formal mode on overloaded
2288 * sem_ch6.ads, sem_ch13.ads: typos in comments.
2290 2011-08-01 Thomas Quinot <quinot@adacore.com>
2292 * atree.adb: Minor reformatting.
2293 * checks.adb: Minor reformatting.
2295 2011-08-01 Vincent Celier <celier@adacore.com>
2297 * s-parame-vms-ia64.ads: Fix typo in comment
2299 * s-parame-vms-restrict.ads: Removed, unused.
2301 2011-08-01 Javier Miranda <miranda@adacore.com>
2304 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
2306 (Constrain_Index): Remove side effects in the evaluation of the bounds.
2307 * sem_ch3.ads, sem_ch3.adb
2308 (Is_Constant_Bound): New extended version of the subprogram that was
2309 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
2310 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
2311 * sem_aux.ads (Constant_Value): Fix typo in comment.
2312 * checks.adb (Generate_Index_Checks): New implementation which, for
2313 array objects with constant bounds, generates the runtime check
2314 referencing the bounds of the array type. For other cases this routine
2315 provides its previous behavior obtaining such values from the array
2317 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
2319 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
2320 we cannot have semantic interpretations of the new node.
2322 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2324 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
2327 2011-08-01 Arnaud Charlet <charlet@adacore.com>
2329 * sem_ch8.adb: Minor code editing.
2330 * s-vxwext.adb: Remove trailing space.
2331 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
2332 consistency with other files.
2334 2011-08-01 Thomas Quinot <quinot@adacore.com>
2336 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
2338 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2340 * par-ch10.adb: reject parameterized expressions as compilation unit.
2341 * sem_ch4.adb: handle properly conditional expression with overloaded
2342 then_clause and no else_clause.
2344 2011-08-01 Tristan Gingold <gingold@adacore.com>
2346 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
2347 like done by System.Aux_DEC.
2348 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
2350 2011-08-01 Yannick Moy <moy@adacore.com>
2352 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
2353 missing label at end of declaration (subprogram or package)
2354 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
2355 of positional and named parameter association
2356 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
2357 Error_Msg_SP which adds a prefix to the error message giving the name
2358 of the formal language analyzed
2359 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
2360 access result type in subprogram, unconstrained array as result type,.
2361 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
2363 * sem_ch8.adb: Code clean up.
2365 2011-08-01 Javier Miranda <miranda@adacore.com>
2367 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
2368 * einfo.ads (Access_Disp_Table): Fix documentation.
2369 (Dispatch_Table_Wrappers): Fix documentation.
2370 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
2371 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
2372 to enforce the documentation of this attribute.
2373 (Set_Is_Interface): Cleanup the assertion.
2374 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
2375 the Underlying_Type entity before reading attribute Access_Disp_Table.
2376 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
2377 Locate the Underlying_Type before reading attribute Access_Disp_Table.
2378 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
2379 the Underlying_Type entity before reading attribute Access_Disp_Table.
2380 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
2381 Locate the Underlying_Type entity before reading attribute
2384 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2386 * s-poosiz.ads: Additional overriding indicators.
2388 2011-08-01 Yannick Moy <moy@adacore.com>
2390 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
2392 (Analyze_Iteration_Scheme): issue error in formal mode when loop
2393 parameter specification does not include a subtype mark.
2394 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
2395 formal mode on abstract subprogram.
2396 (Analyze_Subprogram_Specification): issue error in formal mode on
2397 user-defined operator.
2398 (Process_Formals): issue error in formal mode on access parameter and
2400 * sem_ch9.adb (Analyze_Abort_Statement,
2401 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
2402 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
2403 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
2404 Analyze_Requeue, Analyze_Selective_Accept,
2405 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
2406 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
2407 issue error in formal mode on user-defined raise statement.
2409 2011-08-01 Thomas Quinot <quinot@adacore.com>
2411 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
2412 declaration being hidden when overriding an implicit inherited
2414 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
2415 (-gnats), do not complain about a source file that contains only a
2418 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2420 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
2421 variable if already set.
2423 2011-08-01 Arnaud Charlet <charlet@adacore.com>
2425 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
2426 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
2427 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
2428 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
2429 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
2430 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
2431 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
2432 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
2433 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
2434 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
2435 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
2436 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
2437 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
2438 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
2439 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
2440 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
2441 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
2442 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
2443 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
2444 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
2445 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
2446 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
2447 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
2448 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
2449 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
2450 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
2451 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
2452 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
2453 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
2454 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
2455 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
2456 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
2457 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
2458 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
2459 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
2460 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
2461 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
2462 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
2463 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
2464 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
2465 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
2466 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
2467 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
2468 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
2469 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
2470 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
2471 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
2472 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
2473 s-osinte-mingw.ads: Update to GPLv3 run-time license.
2474 Use GNAT instead of GNARL.
2476 2011-08-01 Bob Duff <duff@adacore.com>
2478 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
2479 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
2480 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
2483 2011-08-01 Yannick Moy <moy@adacore.com>
2485 * debug.adb (d.D) reverve flag for the SPARK mode
2486 (d.E) reverve flag for SPARK generation mode
2487 (d.F) reverve flag for Why generation mode
2488 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
2489 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
2490 functions which return True when the corresponding modes are set
2491 (Formal_Language): return "spark" or "alfa" when in formal verification
2493 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
2494 Error_Msg to prefix the error message with a tag giving the formal
2496 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
2497 message with a tag giving the formal language
2498 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
2500 (Analyze_Case_Statement): issue error in formal mode on case statement
2501 with a single "others" case alternative
2502 (Analyze_Exit_Statement): issue errors in formal mode on exit
2503 statements which do not respect SPARK restrictions
2504 (Analyze_Goto_Statement): issue error in formal mode on goto statement
2505 (Check_Unreachable_Code): always issue an error (not a warning) in
2506 formal mode on unreachable code (concerns both code after an infinite
2507 loop and after an unconditional jump, both not allowed in SPARK)
2508 * sem_ch6.adb (Analyze_Return_Statement): add call to
2509 Set_Return_Present for a procedure containing a return statement
2510 (already done for functions in Analyze_Function_Return)
2511 (Analyze_Function_Return): issue error in formal mode on extended
2512 return or if return is not last statement in function
2513 (Check_Missing_Return): issue error in formal mode if function does
2514 not end with return or if procedure contains a return
2515 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
2516 function to detect if there is an inner scope of its parameter S which
2519 2011-08-01 Thomas Quinot <quinot@adacore.com>
2521 * sem_ch6.ads: Minor reformatting.
2523 2011-08-01 Javier Miranda <miranda@adacore.com>
2525 * sem_util.adb (Abstract_Interface_List): Complete condition when
2526 processing private type declarations to avoid reading unavailable
2528 (Is_Synchronized_Tagged_Type): Complete condition when processing
2529 private extension declaration nodes to avoid reading unavailable
2532 2011-08-01 Thomas Quinot <quinot@adacore.com>
2534 * sem_ch3.adb: Minor reformatting.
2536 2011-08-01 Thomas Quinot <quinot@adacore.com>
2538 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
2539 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
2540 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
2541 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
2542 for VMS, instead parametrize the common implementation with
2543 System.Parameters declarations.
2545 2011-08-01 Eric Botcazou <ebotcazou@adacore.com>
2547 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
2549 2011-08-01 Tristan Gingold <gingold@adacore.com>
2551 * seh_init.c: Fix SEH handler installation on win64.
2553 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2555 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
2556 double analysis of an anonymous access to subprogram, because it can
2557 lead to improper sharing of profiles and a back-end crash.
2559 2011-08-01 Robert Dewar <dewar@adacore.com>
2561 * make.adb, sem_ch4.adb: Minor reformatting.
2562 * gcc-interface/Make-lang.in: Update dependencies.
2563 * sem_util.adb, exp_ch5.adb: Minor reformatting.
2565 2011-08-01 Arnaud Charlet <charlet@adacore.com>
2567 * gnat_rm.texi: Fix definition of Long_Integer.
2569 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2571 * exp_aggr.adb: check limit size of static aggregate unconditionally,
2572 to prevent storage exhaustion.
2573 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
2574 finalized is a function body, insert the cleanup code before the final
2575 return statement, to prevent spurious warnings.
2576 * s-pooglo.ads: add overriding indicator.
2578 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2580 * sem_ch4.adb (Operator_Check): improve error message when both a
2581 with_clause and a use_clause are needed to make operator usage legal.
2582 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
2583 determine whether a compilation unit is visible within an other,
2584 either through a with_clause in the current unit, or a with_clause in
2585 its library unit or one one of its parents.
2587 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2589 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
2590 over an arbitrary expression of an array or container type.
2591 * lib-xref.adb: clarify comment.
2593 2011-08-01 Bob Duff <duff@adacore.com>
2595 * einfo.ads: Minor reformatting.
2596 * debug.adb: Minor comment improvement.
2598 2011-08-01 Javier Miranda <miranda@adacore.com>
2600 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
2601 consider hidden subprograms as valid candidates.
2603 2011-08-01 Arnaud Charlet <charlet@adacore.com>
2605 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
2607 2011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
2609 * gnat_ugn.texi: Fix typo.
2611 2011-08-01 Robert Dewar <dewar@adacore.com>
2613 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
2614 lib-xref.adb: Minor reformatting
2616 2011-08-01 Gary Dismukes <dismukes@adacore.com>
2618 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
2619 when to generate a call to Move_Final_List.
2620 (Has_Controlled_Parts): Remove this function.
2622 2011-08-01 Geert Bosch <bosch@adacore.com>
2624 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
2627 2011-08-01 Thomas Quinot <quinot@adacore.com>
2629 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
2630 explicit raise of a predefined exception as Comes_From_Source if the
2631 original N_Raise_Statement comes from source.
2633 2011-08-01 Robert Dewar <dewar@adacore.com>
2635 * sinfo.ads: Add comment.
2636 * sem_ch6.adb: Minor reformatting.
2638 2011-08-01 Robert Dewar <dewar@adacore.com>
2640 * freeze.adb (Freeze_Entity): Refine check for bad component size
2641 clause to avoid rejecting confirming clause when atomic/aliased present.
2643 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2645 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
2646 better determine whether an entity reference is a write.
2647 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
2649 * lib-xref.adb (Output_References): Do no suppress a read reference at
2650 the same location as an immediately preceeding modify-reference, to
2651 handle properly in-out actuals.
2653 2011-08-01 Tristan Gingold <gingold@adacore.com>
2655 * env.c (__gnat_setenv) [VMS]: Refine previous change.
2657 2011-08-01 Quentin Ochem <ochem@adacore.com>
2659 * i-cstrin.adb (New_String): Changed implementation, now uses only the
2660 heap to compute the result.
2662 2011-08-01 Robert Dewar <dewar@adacore.com>
2664 * atree.ads: Minor reformatting.
2666 2011-08-01 Emmanuel Briot <briot@adacore.com>
2668 * g-expect.adb (Get_Command_Output): Fix memory leak.
2670 2011-08-01 Geert Bosch <bosch@adacore.com>
2672 * cstand.adb (P_Float_Type): New procedure to print the definition of
2673 predefined fpt types.
2674 (P_Mixed_Name): New procedure to print a name using mixed case
2675 (Print_Standard): Use P_Float_Type for printing floating point types
2676 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
2677 precision IEEE float.
2679 2011-08-01 Thomas Quinot <quinot@adacore.com>
2681 * sem_ch3.adb: Minor reformatting.
2683 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2685 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
2686 the completion of a generic function, insert the new body rather than
2687 rewriting the original.
2689 2011-08-01 Yannick Moy <moy@adacore.com>
2691 * sinfo.ads, errout.ads: Typos in comments.
2693 2011-08-01 Robert Dewar <dewar@adacore.com>
2695 * par-endh.adb: Minor reformatting.
2697 2011-08-01 Robert Dewar <dewar@adacore.com>
2699 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
2700 (Pre_Post_Aspects): New subtype.
2701 * par-ch12.adb (P_Generic): New syntax for aspects in packages
2702 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
2703 * par-ch7.adb (P_Package): Remove Decl parameter
2704 (P_Package): Handle new syntax for aspects (before IS)
2705 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
2707 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
2708 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
2709 (P_Package): Remove Decl parameter
2710 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
2712 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
2714 * sem_util.ads, sem_util.adb (Static_Boolean): New function
2715 * sinfo.ads: Document new syntax for aspects in packages etc.
2716 * sprint.adb: Handle new syntax of aspects before IS in package
2718 2011-08-01 Thomas Quinot <quinot@adacore.com>
2720 * atree.ads: Minor reformatting.
2721 * sem_prag.adb: Minor reformatting.
2723 2011-08-01 Robert Dewar <dewar@adacore.com>
2725 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
2726 case expr alternative.
2728 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2730 * sem_ch12.adb: Fix typo.
2732 2011-08-01 Geert Bosch <bosch@adacore.com>
2734 * sem_prag.adb (Check_No_Link_Name): New procedure.
2735 (Process_Import_Or_Interface): Use Check_No_Link_Name.
2736 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
2737 instead of Standard_Long_Long_Float_Size global. Preparation for
2738 eventual removal of per type constants.
2739 * exp_util.ads (Get_Stream_Size): New function returning the stream
2740 size value of subtype E.
2741 * exp_util.adb (Get_Stream_Size): Implement new function.
2742 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
2744 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
2746 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
2748 2011-08-01 Geert Bosch <bosch@adacore.com>
2750 * cstand.adb: Fix comments.
2751 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
2754 2011-08-01 Robert Dewar <dewar@adacore.com>
2756 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
2758 2011-08-01 Geert Bosch <bosch@adacore.com>
2760 * atree.ads: Fix comment.
2762 2011-08-01 Robert Dewar <dewar@adacore.com>
2764 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
2765 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
2766 * par.adb: Add with for Namet.Sp.
2767 * par-tchk.adb: Minor reformatting.
2769 2011-08-01 Vincent Celier <celier@adacore.com>
2771 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
2772 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
2773 of the init procedure of a SAL.
2774 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
2777 2011-08-01 Thomas Quinot <quinot@adacore.com>
2779 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
2782 2011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
2784 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
2786 2011-08-01 Thomas Quinot <quinot@adacore.com>
2788 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
2789 conformant with its spec (return True only for types that have
2790 an overriding Initialize primitive operation that prevents them from
2791 having preelaborable initialization).
2792 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
2793 initialization for controlled types in Ada 2005 or later mode.
2795 2011-08-01 Robert Dewar <dewar@adacore.com>
2797 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
2799 (Same_Aspect): New function.
2800 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
2801 Type_Invariant, Precondition, Postcondition.
2802 * snames.ads-tmpl: Add Name_Type_Invariant.
2804 2011-08-01 Robert Dewar <dewar@adacore.com>
2806 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
2808 (Freeze_All_Ent): Fix error in handling inherited aspects.
2809 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
2810 already analyzed, but don't skip entire processing of a declaration,
2811 that's wrong in some cases of declarations being rewritten.
2812 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
2813 Don't delay for integer, string literals
2814 Treat predicates in usual manner for delay, remove special case code,
2816 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
2817 (Build_Predicate_Function): Update saved expression in aspect
2818 (Build_Invariant_Procedure): Update saved expression in aspect
2819 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
2820 of replacement of discriminant references if the reference is simple.
2822 2011-08-01 Robert Dewar <dewar@adacore.com>
2824 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
2825 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
2826 Static_Predicate and Dynamic_Predicate.
2827 (Build_Predicate_Function): Add processing for Static_Predicate
2828 and Dynamic_Predicate.
2829 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
2830 (From_Static_Predicate): New flag
2831 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
2833 2011-08-01 Robert Dewar <dewar@adacore.com>
2835 * usage.adb: Documentation cleanup for Ada version modes in usage.
2836 * expander.adb: Minor reformatting.
2838 2011-08-01 Robert Dewar <dewar@adacore.com>
2840 * atree.ads: Minor comment fix.
2841 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
2842 a-witeio.ads, sem_prag.adb: Minor reformatting.
2844 2011-08-01 Doug Rupp <rupp@adacore.com>
2846 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
2847 pointers. Use descrip.h header file for convenience. Add some
2850 2011-08-01 Robert Dewar <dewar@adacore.com>
2852 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
2853 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
2854 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
2856 (Check_Aspect_At_End_Of_Declarations): New procedure
2857 (Analye_Aspect_Specification): Minor changes for above procedures
2858 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
2859 specification node as well.
2861 2011-08-01 Pascal Obry <obry@adacore.com>
2863 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
2864 Windows files. Use GetFilesAttributes() in this case to check for file
2865 existence instead of returning with an error code.
2867 2011-08-01 Vincent Celier <celier@adacore.com>
2869 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
2870 High is above Source length.
2872 2011-08-01 Robert Dewar <dewar@adacore.com>
2874 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
2876 2011-08-01 Robert Dewar <dewar@adacore.com>
2878 * aspects.ads (Boolean_Aspects): New subtype.
2879 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
2880 for derived types in cases where the parent type and derived type have
2882 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
2883 with aspects when parent type also has aspects.
2884 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
2885 boolean expression at this point).
2886 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
2887 accordance with final decision on the Ada 2012 feature.
2888 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
2890 2011-08-01 Matthew Heaney <heaney@adacore.com>
2892 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
2894 2011-08-01 Pascal Obry <obry@adacore.com>
2896 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
2897 Fix Replace_Slice when High is above current string size.
2898 (Replace_Slice): Fix DL computation when High is above current
2901 2011-08-01 Gary Dismukes <dismukes@adacore.com>
2903 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
2905 2011-08-01 Matthew Heaney <heaney@adacore.com>
2907 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
2910 2011-08-01 Pascal Obry <obry@adacore.com>
2912 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
2915 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2917 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
2918 access to protected subprograms in generic bodies.
2919 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
2920 protected type, indicate that the convention of the subprogram is
2921 Convention_Protected, because it may be used in subsequent declarations
2922 within the protected declaration.
2924 2011-08-01 Vincent Celier <celier@adacore.com>
2926 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
2927 and "final" procedures when the name of the library is "ada", to avoid
2928 duplicate symbols "adainit" and "adafinal" in executables.
2930 2011-08-01 Ed Schonberg <schonberg@adacore.com>
2932 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
2933 quantified expression that appears within a postcondition and uses the
2934 Ada2012 'Result attribute.
2936 2011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2938 * init.c (__gnat_error_handler): Cast reason to int.
2939 (__gnat_install_handler): Explain sa_sigaction use.
2941 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
2943 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
2944 subprogram has copy-in copy-out parameters, try to promote the mode of
2945 the return type if it is passed in registers.
2947 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
2949 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
2950 left operand as addressable.
2952 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
2954 * gcc-interface/gigi.h (build_function_stub): Remove.
2955 (build_return_expr): Likewise.
2956 (convert_vms_descriptor): Declare.
2957 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
2958 (build_function_stub): Move to...
2959 * gcc-interface/utils2.c (build_return_expr): Move to...
2960 * gcc-interface/trans.c (build_function_stub): ...here.
2961 (build_return_expr): ...here.
2962 (Subprogram_Body_to_gnu): Add local variable for language_function.
2963 Disconnect the parameter attributes cache, if any, once done with it.
2964 Call end_subprog_body only after setting the end_locus.
2965 Build the stub associated with the function, if any, at the very end.
2966 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
2967 variables and streamline control flow.
2969 2011-07-23 Arnaud Charlet <charlet@adacore.com>
2972 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
2975 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2978 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
2979 Assign to act.sa_sigaction.
2980 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
2981 current->return_address to char * before arithmetic.
2983 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2985 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
2986 Correct argument types.
2987 Extract code from reason.
2988 (__gnat_install_handler): Assign to act.sa_sigaction.
2990 2011-07-21 Eric Botcazou <ebotcazou@adacore.com>
2992 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
2993 (GNAT1_OBJS): ...here.
2995 2011-07-15 Eric Botcazou <ebotcazou@adacore.com>
2998 * g-socthi-mingw.adb (Fill): Fix formatting.
3000 * gcc-interface/gigi.h: Move around comment.
3002 2011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
3005 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
3007 2011-07-14 Florian Weimer <fw@deneb.enyo.de>
3010 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
3012 2011-07-13 Eric Botcazou <ebotcazou@adacore.com>
3014 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
3015 range comparison if Pmode is SImode.
3017 2011-07-12 Laurent GUERBY <laurent@guerby.net>
3018 Eric Botcazou <ebotcazou@adacore.com>
3020 * adadecode.c: Wrap up in extern "C" block.
3021 * adadecode.h: Likewise.
3022 * adaint.c: Likewise. Remove 'const' keyword.
3023 * adaint.h: Likewise.
3025 * atree.h: Likewise.
3027 * cstreams.c: Likewise.
3031 * final.c: Likewise.
3033 * initialize.c: Likewise.
3035 * namet.h: Likewise.
3036 * nlists.h: Likewise.
3037 * raise.c: Likewise.
3038 * raise.h: Likewise.
3039 * repinfo.h: Likewise.
3040 * seh_init.c: Likewise.
3041 * targext.c: Likewise.
3042 * tracebak.c: Likewise.
3043 * uintp.h: Likewise.
3044 * urealp.h: Likewise.
3045 * xeinfo.adb: Wrap up generated C code in extern "C" block.
3046 * xsinfo.adb: Likewise.
3047 * xsnamest.adb: Likewise.
3048 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
3049 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
3050 * gcc-interface/misc.c: Likewise.
3051 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
3052 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
3053 ada/targext.o here...
3054 (GNAT_ADA_OBJS): ...and not here.
3055 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
3056 (GNATBIND_OBJS): Reorder.
3058 2011-07-07 Richard Henderson <rth@redhat.com>
3060 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
3061 dwarf2out_frame_init.
3063 2011-07-07 Eric Botcazou <ebotcazou@adacore.com>
3065 * gcc-interface/misc.c (gnat_init): Tweak previous change.
3067 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3070 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
3072 2011-07-06 Richard Guenther <rguenther@suse.de>
3074 * gcc-interface/misc.c (gnat_init): Merge calls to
3075 build_common_tree_nodes and build_common_tree_nodes_2.
3076 Re-initialize boolean_false_node.
3078 2011-07-02 Eric Botcazou <ebotcazou@adacore.com>
3079 Olivier Hainque <hainque@adacore.com>
3080 Nicolas Setton <setton@adacore.com>
3082 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
3083 the type according to the ARTIFICIAL_P parameter.
3084 (create_type_decl): Likewise.
3085 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
3087 2011-07-01 Eric Botcazou <ebotcazou@adacore.com>
3089 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
3090 (gnatbind): Likewise.
3092 2011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3094 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
3096 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
3098 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
3099 local variable throughout. Remove useless call to Base_Type.
3100 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
3101 Take it also into account for the volatileness of the field. Set the
3102 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
3104 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
3106 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
3107 on a dereference built for a by-ref object if it has an address clause.
3109 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
3111 * einfo.ads (Address_Taken): Document use for the second argument of
3112 Asm_Input and Asm_Output attributes.
3113 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
3114 argument is an entity name, then set Address_Taken on it.
3115 <Attribute_Asm_Output>: Likewise.
3116 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
3117 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
3118 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
3119 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
3121 2011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
3124 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
3126 2011-06-14 Joseph Myers <joseph@codesourcery.com>
3128 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
3129 (ada/utils.o): Update dependencies.
3130 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
3131 ../../../libcpp/libcpp.a.
3132 * gcc-interface/utils.c: Include common/common-target.h.
3133 (process_attributes): Use targetm_common.have_named_sections.
3135 2011-06-07 Richard Guenther <rguenther@suse.de>
3137 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
3140 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3142 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3143 TREE_THIS_NOTRAP flag.
3145 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3147 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
3150 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3152 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
3153 constants whose full view has discriminants specially.
3155 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3157 * gcc-interface/utils.c: Include diagnostic.h.
3158 (gnat_write_global_declarations): Output debug information for all
3159 global type declarations before finalizing the compilation unit.
3160 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
3162 2011-05-25 Jakub Jelinek <jakub@redhat.com>
3164 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
3166 2011-05-25 Kai Tietz <ktietz@redhat.com>
3168 * adaint.c (__gnat_to_canonical_file_list_next): Use array
3169 initialization instead of const/none-const pointer assignment.
3171 2011-05-24 Joseph Myers <joseph@codesourcery.com>
3173 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
3174 $(EXTRA_GNAT1_OBJS).
3175 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
3176 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
3177 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
3178 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
3179 libcommon-target.a instead of prefix.o.
3181 2011-05-21 Joseph Myers <joseph@codesourcery.com>
3184 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
3186 2011-05-20 Joseph Myers <joseph@codesourcery.com>
3188 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
3189 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
3190 instead of version.o.
3192 2011-05-18 Kai Tietz <ktietz@redhat.com>
3194 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
3195 boolean_false_node instead of integer_zero_node.
3196 (convert_with_check): Likewise.
3197 * gcc-interface/decl.c (choices_to_gnu): Likewise.
3199 2011-05-12 Eric Botcazou <ebotcazou@adacore.com>
3201 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
3202 type of the parameter is an unconstrained array, convert the actual to
3203 the type of the formal in the In Out and Out cases as well.
3205 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
3207 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
3208 call build_function_type_array or build_varargs_function_type_array
3210 (create_subprog_type): Don't call build_function_type; call
3211 build_function_type_vec instead.
3213 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
3215 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
3216 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
3217 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
3219 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
3221 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
3223 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
3224 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
3226 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
3228 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3230 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
3232 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
3233 instead of accessing TYPE_ARG_TYPES directly.
3234 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
3236 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
3239 * gcc-interface/gigi.h (get_variant_part): Declare.
3240 * gcc-interface/decl.c (get_variant_part): Make global.
3241 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
3242 types have the same constant size, are record types and T1 has a
3243 variant part while T2 doesn't.
3245 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
3247 * gcc-interface/utils.c (begin_subprog_body): Do not call
3249 (end_subprog_body): Likewise.
3251 2011-05-04 Richard Guenther <rguenther@suse.de>
3253 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
3255 (pos_to_constructor): Likewise.
3257 2011-05-03 Nathan Froyd <froydnj@codesourcery.com>
3258 Eric Botcazou <ebotcazou@adacore.com>
3260 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
3261 of build_function_type. Adjust calls to...
3262 (build_raise_check): ...this. Do not take a void_tree parameter.
3263 Call build_function_type_list instead of build_function_type.
3264 Fix head comment and swap couple of conditional blocks.
3266 2011-04-30 Eric Botcazou <ebotcazou@adacore.com>
3268 * gnatvsn.ads (Library_Version): Bump to 4.7.
3269 (Current_Year): Bump to 2011.
3271 2011-04-29 Michael Matz <matz@suse.de>
3273 * gcc-interface/misc.c (gnat_handle_option): Set
3274 warn_maybe_uninitialized.
3276 2011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
3278 * gnat_ugn.texi (Complexity Metrics Control): Update link to
3279 the Watson/McCabe paper.
3281 2011-04-23 Jim Meyering <meyering@redhat.com>
3283 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
3285 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
3287 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
3290 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
3292 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
3294 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
3295 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
3296 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
3297 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
3298 <all>: Do not set flags on the reused DECL node coming from an alias.
3299 Set DECL_IGNORED_P on the DECL node built for subprograms if they
3300 don't need debug info here...
3301 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
3302 (gigi): Adjust calls to create_subprog_decl.
3303 (build_raise_check): Likewise.
3304 (establish_gnat_vms_condition_handler): Likewise.
3305 (Compilation_Unit_to_gnu): Likewise.
3306 (gnat_to_gnu): Likewise.
3308 2011-04-21 Eric Botcazou <ebotcazou@adacore.com>
3310 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
3311 (NO_REORDER_ADAFLAGS): New variable.
3312 (EXTRA_GNATTOOLS): Always define.
3313 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
3314 Clean up and adjust list of files compiled with special options.
3315 * gcc-interface/Make-lang.in: Likewise.
3316 (ada/decl.o): Cosmetical change.
3317 (ada/misc.o): Remove dependency on $(PLUGIN_H).
3319 2011-04-20 Jim Meyering <meyering@redhat.com>
3321 * initialize.c (__gnat_initialize): Remove useless if-before-free.
3323 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
3325 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
3326 $(CFLAGS) on the link line.
3328 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
3330 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
3331 padded type built for the return type if it is unconstrained.
3333 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
3335 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
3337 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
3339 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
3340 before calling TREE_CHAIN.
3341 * gcc-interface/misc.c (gnat_init_ts): New function.
3342 (LANG_HOOKS_INIT_TS): Define.
3344 2011-04-12 Martin Jambor <mjambor@suse.cz>
3346 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
3347 instead of cgraph_node.
3349 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
3351 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
3352 alignment on fields of the RETURN type built for the Copy-In Copy-Out
3355 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
3357 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
3358 of aggregate types that contain a placeholder.
3360 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
3362 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
3364 (handle_type_generic_attribute): Likewise.
3366 2011-04-04 Eric Botcazou <ebotcazou@adacore.com>
3369 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
3371 2011-04-04 Kai Tietz <ktietz@redhat.com>
3374 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
3377 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3379 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
3380 type case, do not strip a padding type around the array type.
3382 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3384 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
3387 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3389 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
3390 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
3391 code for -feliminate-unused-debug-types.
3392 (gnat_post_options): Likewise.
3394 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3396 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
3397 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
3400 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3402 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
3403 DECL_ARTIFICIAL flag on enumeration types.
3405 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3407 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
3408 fat pointer types artificial unconditionally.
3409 <E_Array_Subtype>: Attach the base array type as a parallel type if it
3412 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3414 * gcc-interface/gigi.h (get_dummy_type): Declare.
3415 (build_dummy_unc_pointer_types): Likewise.
3416 (finish_fat_pointer_type): Likewise.
3417 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
3418 fat pointer type has been built, complete it in place.
3419 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
3420 and thin pointers. Remove useless variable.
3421 (finish_fat_pointer_type): Make global and move to...
3422 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
3423 (get_dummy_type): New function.
3424 (build_dummy_unc_pointer_types): Likewise.
3425 (gnat_pushdecl): Propage the name to the anonymous variants only.
3426 (update_pointer_to): Only adjust the pointer types in the unconstrained
3429 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3431 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
3432 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
3433 if this is a Taft amendment type and the full declaration is available.
3434 * gcc-interface/trans.c (process_type): Likewise.
3435 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
3436 (process_freeze_entity): Likewise.
3437 * gcc-interface/utils.c (dummy_global): New static variable.
3438 (gnat_write_global_declarations): If there are types declared as used
3439 at the global level, insert them in the global hash table.
3441 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3443 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
3444 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
3445 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
3447 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
3448 flag of the type accordingly.
3449 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
3451 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3453 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
3454 finalizing types when updating the pointers to the designated type.
3455 <all>: Finalize the deferred types even if we didn't defer processing
3456 of incomplete types in this invocation.
3458 2011-04-01 Olivier Hainque <hainque@adacore.com>
3459 Nicolas Setton <setton@adacore.com>
3460 Eric Botcazou <ebotcazou@adacore.com>
3462 * gcc-interface/misc.c (gnat_descriptive_type): New function.
3463 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
3465 2011-03-28 Kai Tietz <ktietz@redhat.com>
3467 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
3469 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
3470 * system-mingw.ads (System): Change ZCX_By_Default default to True.
3472 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
3474 2011-03-28 Tristan Gingold <gingold@adacore.com>
3477 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
3478 Use ada output of gnatbind.
3479 (ada/b_gnatb.adb): Ditto.
3480 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
3481 (ada.mostlyclean, ada.stage1)
3482 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
3483 (ada.stagefeedback): Adjust.
3484 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
3485 Use ada output of gnatbind.
3486 (b_gnatm.adb): Ditto.
3487 (b_gnatl.o, b_gnatm.o): New rules.
3489 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
3491 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
3492 for the padded type built to support a specified size or alignment.
3494 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
3496 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
3497 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
3498 unconditionally to the end of the unit when the designated type is
3500 <all>: Rename local variable. Attempt to un-defer types only and do it
3501 for limited_with'ed types as well.
3502 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
3503 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
3504 consistently and remove redundant call to finalize_from_with_types.
3506 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
3508 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
3509 subprograms without a previous spec declared in the same unit.
3510 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
3511 subprograms at the end of the unit instead of at the beginning.
3512 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
3513 isn't public for the special handling of non-inline functions nested
3514 inside inline external functions.
3516 2011-03-25 Jeff Law <law@redhat.com>
3518 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
3520 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
3522 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
3523 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
3524 to compute Set_Size_Depends_On_Discriminant.
3525 (Layout_Type): Call it on array types in back-end layout mode.
3526 * sem_util.adb (Requires_Transient_Scope): Return true for array
3527 types only if the size depends on the value of discriminants.
3528 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
3529 type if the RHS is a call to a function that returns an unconstrained
3530 type with default discriminant.
3532 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
3534 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
3535 non-conversion to the nominal result type at the end.
3537 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
3539 * gcc-interface/trans.c (create_temporary): New function taken from...
3540 (create_init_temporary): ...here. Call it.
3541 (call_to_gnu): Create the temporary for the return value early, if any.
3542 Create it for a function with copy-in/copy-out parameters if there is
3543 no target; in other cases of copy-in/copy-out, use another temporary.
3544 Push the new binding level lazily. Add and rename local variables.
3546 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
3548 * gcc-interface/decl.c (validate_size): Improve comments and tweak
3550 (set_rm_size): Likewise.
3552 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
3554 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
3555 for the padded type built in order to support a specified alignment.
3556 Fix incorrect formatting.
3558 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
3561 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
3563 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
3565 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
3566 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
3567 to the end of the list. Adjust recursive call. Rename local variable.
3568 If REORDER is true, reorder components of the record type.
3569 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
3570 components_to_record and adjust the parameter list.
3572 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
3574 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
3575 disabled, use the variable for bounds of loop iteration scheme.
3577 2011-03-21 Kai Tietz <ktietz@redhat.com>
3580 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
3582 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
3584 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
3585 out whether the expression is read-only. Short-circuit placeholder
3586 case and rename a couple of local variables.
3588 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
3590 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
3591 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
3592 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
3593 (convert): Deal with conversions from a smaller form type specially.
3595 2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
3597 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
3598 its argument, except for the special -I- switch.
3600 2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
3602 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
3605 2011-02-08 Eric Botcazou <ebotcazou@adacore.com>
3607 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
3609 2011-02-03 Eric Botcazou <ebotcazou@adacore.com>
3611 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
3613 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
3614 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
3615 instead of GNAT_FORMAL. Protect the expression against multiple uses.
3616 Do not generate the check directly, instead instantiate the template
3617 check present in the descriptor.
3618 (make_descriptor_field): Move around.
3619 (build_vms_descriptor32): Build a template check in the POINTER field.
3620 (build_vms_descriptor): Remove useless suffixes.
3621 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
3623 2011-01-26 Eric Botcazou <ebotcazou@adacore.com>
3626 * targext.c: Include target files if IN_RTS is defined.
3628 2011-01-26 Richard Guenther <rguenther@suse.de>
3631 * targext.c: Include config.h.
3632 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
3635 2011-01-04 Pascal Obry <obry@adacore.com>
3636 Eric Botcazou <ebotcazou@adacore.com>
3638 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
3640 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
3642 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
3643 end-of-case on the end label and its associated gotos, if any.
3645 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
3647 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
3648 expressions of the parameter cache within the statement group of
3651 2011-01-04 Olivier Hainque <hainque@adacore.com>
3652 Eric Botcazou <ebotcazou@adacore.com>
3654 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
3655 (set_end_locus_from_node): New function.
3656 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
3657 make and the function end_locus.
3658 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
3659 for the elaboration subprogram.
3660 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
3661 set the end_locus of the expression as well.
3663 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
3666 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
3667 variables that are referenced in exception handlers volatile.
3671 Copyright (C) 2011 Free Software Foundation, Inc.
3673 Copying and distribution of this file, with or without modification,
3674 are permitted in any medium without royalty provided the copyright
3675 notice and this notice are preserved.
3677 * gnat_rm.texi: Ramification of pragma Eliminate documentation
3678 - fix bugs in the description of Source_Trace;
3679 - get rid of UNIT_NAME;
3681 2011-08-02 Javier Miranda <miranda@adacore.com>
3684 (Build_Dispatching_Requeue): Adding support for VM targets
3685 since we cannot directly reference the Tag entity.
3686 * exp_sel.adb (Build_K): Adding support for VM targets.
3687 (Build_S_Assignment): Adding support for VM targets.
3689 (Default_Prim_Op_Position): In VM targets do not restrict availability
3690 of predefined interface primitives to compiling in Ada 2005 mode.
3691 (Is_Predefined_Interface_Primitive): In VM targets this service is not
3692 restricted to compiling in Ada 2005 mode.
3693 (Make_VM_TSD): Generate code that declares and initializes the OSD
3694 record. Needed to support dispatching calls through synchronized
3697 (Make_Predefined_Primitive_Specs): Enable generation of predefined
3698 primitives associated with synchronized interfaces.
3699 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
3700 primitives associated with synchronized interfaces.
3702 2011-08-02 Yannick Moy <moy@adacore.com>
3704 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
3705 statements hidden in SPARK if preceded by the HIDE directive
3706 (Parse_Exception_Handlers): mark each exception handler in a sequence of
3707 exception handlers as hidden in SPARK if preceded by the HIDE directive
3708 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
3709 if starting with the HIDE directive
3710 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
3711 starting with the HIDE directive; mark the declarations in a private
3712 part as hidden in SPARK if the private part starts with the HIDE
3714 * restrict.adb, restrict.ads
3715 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
3716 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
3717 argument node belongs to a part which is hidden in SPARK
3718 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
3719 parts in SPARK; protect the possibly costly call to
3720 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
3721 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
3722 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
3723 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
3725 (Scan): recognize special comment starting with '#' and followed by
3726 SPARK keyword "hide" as a HIDE directive.
3728 2011-08-02 Yannick Moy <moy@adacore.com>
3730 * types.ads, erroutc.ads: Minor reformatting.
3732 2011-08-02 Vincent Celier <celier@adacore.com>
3734 * link.c: Add response file support for cross platforms.
3736 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3738 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
3739 in an association, set parent field of copy before partial analysis.
3740 * sem_res.adb (Resolve_Slice): create reference to itype only when
3741 expansion is enabled.
3743 2011-08-02 Yannick Moy <moy@adacore.com>
3745 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
3746 for new flag denoting which subprogram bodies are in ALFA
3747 * restrict.adb, sem_ch7.adb: Update comment
3748 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
3749 sem_ch9.adb, sem_res.adb: Add calls to
3750 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
3751 * sem_ch6.adb (Analyze_Function_Return): add calls to
3752 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
3753 middle of the body, and extended return.
3754 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
3755 False when missing return.
3756 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
3757 to True for subprograms whose spec is in ALFA. Remove later on the flag
3758 on the entity used for a subprogram body when there exists a separate
3760 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
3761 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
3762 False, otherwise do nothing.
3764 2011-08-02 Robert Dewar <dewar@adacore.com>
3766 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
3768 2011-08-02 Yannick Moy <moy@adacore.com>
3770 * sem_ch4.ads: minor formatting.
3772 2011-08-02 Yannick Moy <moy@adacore.com>
3774 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
3775 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
3776 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
3777 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
3778 opt.ads: cleanup of SPARK mode
3780 2011-08-02 Yannick Moy <moy@adacore.com>
3782 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
3784 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
3785 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
3787 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
3788 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
3789 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
3790 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
3792 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
3794 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
3795 functions whose return type is not in ALFA.
3796 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
3798 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
3799 parameter's type is not in ALFA.
3800 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
3803 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3805 * sem_ch6 (Analyze_Expression_Function): treat the function as
3806 Inline_Always, and introduce a subprogram declaration for it when it is
3808 * inline.adb (Add_Inlined_Body): recognize bodies that come from
3809 expression functions, so that the back-end can determine whether they
3810 can in fact be inlined.
3811 * sem_util.adb (Is_Expression_Function): predicate to determine whether
3812 a function body comes from an expression function.
3814 2011-08-02 Gary Dismukes <dismukes@adacore.com>
3816 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
3817 null exclusions to test Can_Never_Be_Null on the anonymous access types
3818 of the formals rather than testing the formals themselves. Exclude this
3819 check in cases where the Old_Formal is marked as a controlling formal,
3820 to avoid issuing spurious errors for bodies completing dispatching
3821 operations (due to the flag not getting set on controlling access
3822 formals in body specs).
3823 (Find_Corresponding_Spec): When checking full and subtype conformance of
3824 subprogram bodies in instances, pass Designated and E in that order, for
3825 consistency with the expected order of the formals (New_Id followed by
3828 2011-08-02 Robert Dewar <dewar@adacore.com>
3830 * sem_ch8.adb: Minor reformatting.
3832 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3834 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
3835 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
3836 primitive operations of class-wide actuals.
3838 2011-08-02 Javier Miranda <miranda@adacore.com>
3840 * exp_atag.ads, exp_atag.adb
3841 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
3842 since its value is implicitly passed in argument Typ.
3843 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
3844 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
3845 Build_Common_Dispatching_Select_Statements.
3847 2011-08-02 Robert Dewar <dewar@adacore.com>
3849 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
3850 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
3853 2011-08-02 Robert Dewar <dewar@adacore.com>
3855 * sem_res.adb: Minor reformatting.
3856 * sem_prag.adb: Minor reformatting.
3858 2011-08-02 Javier Miranda <miranda@adacore.com>
3860 * exp_atag.adb, exp_atags.ads
3861 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
3862 by the tagged type Entity. Required to use this routine in the VM
3863 targets since we do not have available the Tag entity in the VM
3866 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
3867 Ada.Tags has not been previously loaded.
3869 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
3870 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
3872 (Enclosing_Dynamic_Scope): Add missing support to handle the full
3873 view of enclosing scopes. Required to handle enclosing scopes that
3874 are synchronized types whose full view is a task type.
3876 (Build_VM_TSDs): Minor code improvement to avoid generating and
3877 analyzing lists with empty nodes.
3878 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
3879 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
3880 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
3881 (Make_Disp_Timed_Select_Body): Add support for VM targets.
3882 (Make_Select_Specific_Data_Table): Add support for VM targets.
3883 (Make_VM_TSD): Generate code to initialize the SSD structure of
3886 2011-08-02 Yannick Moy <moy@adacore.com>
3888 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
3889 cross-references section in ALI.
3890 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
3891 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
3893 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
3894 subprogram or package entity of a node
3895 (Is_Local_Reference_Type): new function returns True for references
3896 selected in local cross-references.
3897 (Lt): function extracted from Lt in Output_References
3898 (Write_Entity_Name): function extracted from Output_References
3899 (Generate_Definition): generate reference with type 'D' for definition
3900 of objects (object declaration and parameter specification), with
3901 appropriate locations and units, for use in local cross-references.
3902 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
3903 references of type 'I' for initialization in object definition.
3904 (Output_References): move part of function Lt and procedure
3905 Write_Entity_Name outside of the body. Ignore references of types 'D'
3906 and 'I' introduced for local cross-references.
3907 (Output_Local_References): new procedure to output the local
3908 cross-references sections.
3909 (Lref_Entity_Status): new array defining whether an entity is a local
3910 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
3911 with 'I' type when initialization expression is present.
3912 * get_scos.adb, get_scos.ads: Correct comments and typos
3914 2011-08-02 Javier Miranda <miranda@adacore.com>
3916 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
3918 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
3920 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
3923 2011-08-02 Vincent Celier <celier@adacore.com>
3925 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
3926 (No_Space_Img): New function
3927 (Find_Excluded_Sources): When reading from a file, record the file name
3928 and the line number for each excluded source.
3929 (Mark_Excluded_Sources): When reporting an error, if the excluded
3930 sources were read from a file, include file name and line number in
3933 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3935 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
3937 2011-08-02 Robert Dewar <dewar@adacore.com>
3939 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
3941 2011-08-02 Javier Miranda <miranda@adacore.com>
3943 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
3944 generation of TSDs to the DOTNET compiler.
3945 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
3946 generation of TSDs to the DOTNET compiler.
3948 2011-08-02 Javier Miranda <miranda@adacore.com>
3950 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
3951 record of all the tagged types declared inside library level package
3952 declarations, library level package bodies or library level subprograms.
3953 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
3954 associated with a given tagged type.
3955 (Build_VM_TSDs): New subprogram.
3956 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
3957 compilation units that are subprograms.
3958 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
3959 compilation units that are package bodies.
3960 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
3961 units that are a package declaration or a package instantiation.
3962 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
3963 reorganization to improve the error generated by the frontend when the
3964 function Ada.Tags.Secondary_Tag is not available.
3965 * rtsfind.ads (RE_Register_TSD): New runtime entity.
3966 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
3968 2011-08-02 Javier Miranda <miranda@adacore.com>
3970 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
3972 2011-08-02 Robert Dewar <dewar@adacore.com>
3974 * s-imenne.ads: Minor reformatting.
3976 2011-08-02 Robert Dewar <dewar@adacore.com>
3978 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
3979 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
3980 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
3982 2011-08-02 Robert Dewar <dewar@adacore.com>
3984 * einfo.ads (Materialize_Entity): Document this is only for renamings
3985 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
3986 required debug information in the case where we transform the object
3987 declaration into a renaming declaration.
3988 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
3990 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
3993 2011-08-02 Robert Dewar <dewar@adacore.com>
3995 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
3996 Suppress_Init_Procs.
3997 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
3998 Suppress_Initialization/Initialization_Suppressed.
3999 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
4000 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
4001 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
4002 * sem_prag.adb: New processing for pragma Suppress_Initialization.
4004 2011-08-02 Robert Dewar <dewar@adacore.com>
4006 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
4009 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4011 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
4012 only have inheritable classwide pre/postconditions.
4014 2011-08-02 Javier Miranda <miranda@adacore.com>
4016 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
4017 * rtsfind.ads (RE_Check_TSD): New runtime entity.
4018 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
4019 checks if the external tag of a type is the same as the external tag
4020 of some other declaration.
4022 2011-08-02 Thomas Quinot <quinot@adacore.com>
4024 * s-taskin.ads: Minor reformatting.
4026 2011-08-02 Emmanuel Briot <briot@adacore.com>
4028 * g-comlin.adb (Display_Help): swap the order in which it prints the
4029 short help and the general usage.
4031 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4033 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
4034 the aspect declarations and attach them to the generic copy for
4035 subsequent analysis.
4036 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
4037 declarations of the generic tree to the new subprogram declarations.
4038 * sem_attr.adb (Check_Precondition_Postcondition): recognize
4039 conditions that apply to a subprogram instance.
4041 2011-08-02 Robert Dewar <dewar@adacore.com>
4043 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
4045 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4047 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
4048 private type with a tagged full view is not derived in the immediate
4049 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
4051 2011-08-02 Robert Dewar <dewar@adacore.com>
4053 * exp_ch4.adb: Minor reformatting.
4055 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4057 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
4058 Ada2012 iterator, the loop will be rewritten during expansion into a
4059 while loop with a cursor and an element declaration. Do not analyze the
4060 body in this case, because if the container is for indefinite types the
4061 actual subtype of the elements will only be determined when the cursor
4062 declaration is analyzed.
4064 2011-08-02 Arnaud Charlet <charlet@adacore.com>
4066 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
4067 size/alignment related attributes in CodePeer_Mode.
4069 2011-08-02 Gary Dismukes <dismukes@adacore.com>
4071 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
4072 Prepend_Element, since this can result in the operation getting the
4073 wrong slot in the full type's dispatch table if the full type has
4074 inherited operations. The incomplete type's operation will get added
4075 to the proper position in the full type's primitives
4076 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
4077 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
4078 dispatching operations, since there are cases where nonprimitive
4079 subprograms can get added to the list of incomplete dependents (such
4080 as subprograms in nested packages).
4081 * sem_ch6.adb (Process_Formals): First, remove test for being in a
4082 private part when determining whether to add a primitive with a
4083 parameter of a tagged incomplete type to the Private_Dependents list.
4084 Such primitives can also occur in the visible part, and should not have
4085 been excluded from being private dependents.
4086 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
4087 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
4088 list of a Taft-amendment incomplete type is a primitive before issuing
4089 an error that the full type must appear in the same unit. There are
4090 cases where nonprimitives can be in the list (such as subprograms in
4092 * sem_disp.adb (Derives_From): Use correct condition for checking that
4093 a formal's type is derived from the type of the corresponding formal in
4094 the parent subprogram (the condition was completely wrong). Add
4095 checking that was missing for controlling result types being derived
4096 from the result type of the parent operation.
4098 2011-08-02 Yannick Moy <moy@adacore.com>
4100 * errout.adb (First_Node): minor renaming
4101 * restrict.adb (Check_Formal_Restriction): put restriction warning on
4104 2011-08-02 Yannick Moy <moy@adacore.com>
4106 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
4107 before accessing operands.
4108 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
4109 decide whether an initialization expression respects SPARK rules, as
4110 the plain node is the expanded one. This allows for more valid warnings
4112 * gnat_rm.texi: Minor update.
4114 2011-08-02 Arnaud Charlet <charlet@adacore.com>
4116 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
4119 2011-08-02 Robert Dewar <dewar@adacore.com>
4121 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
4123 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
4125 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
4126 loop statements and the element renaming declaration with a block when
4127 the element type is controlled.
4129 2011-08-02 Yannick Moy <moy@adacore.com>
4131 * sinfo.ads: Minor formatting.
4133 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4135 * sem_aggr.adb (Add_Association): if the association has a box and no
4136 expression, use the Sloc of the aggregate itself for the new
4138 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
4141 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
4143 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
4144 When a container is provided via a function call, generate a renaming
4145 of the function result. This avoids the creation of a transient scope
4146 and the premature finalization of the container.
4147 * exp_ch7.adb (Is_Container_Cursor): Removed.
4148 (Wrap_Transient_Declaration): Remove the supression of the finalization
4149 of the list controller when the declaration denotes a container cursor,
4152 2011-08-02 Yannick Moy <moy@adacore.com>
4154 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
4155 node is from source, instead of the original node being from source.
4157 (Resolve_Array_Aggregate): refine the check for a static expression, to
4158 recognize also static ranges
4159 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
4160 Array_Type_Declaration): postpone the test for the type being a subtype
4161 mark after the type has been resolved, so that component-selection and
4162 expanded-name are discriminated.
4163 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
4164 to distinguish the case of an iteration scheme, so that an error is
4165 issed on a non-static range in SPARK except in an iteration scheme.
4166 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
4167 In_Iter_Schm = True.
4168 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
4169 user-defined operators so that they are allowed in renaming
4171 (Find_Selected_Component): refine the check for prefixing of operators
4172 so that they are allowed in renaming. Move the checks for restrictions
4173 on selector name after analysis discriminated between
4174 component-selection and expanded-name.
4175 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
4176 concatenation argument of string type if it is static.
4177 * sem_util.adb, sem_util.ads
4178 (Check_Later_Vs_Basic_Declarations): add a new function
4179 Is_Later_Declarative_Item to decice which declarations are allowed as
4180 later items, in the two different modes Ada 83 and SPARK. In the SPARK
4181 mode, add that renamings are considered as later items.
4182 (Enclosing_Package): new function to return the enclosing package
4183 (Enter_Name): correct the rule for homonyms in SPARK
4184 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
4185 from source (result of expansion) to avoid issuing wrong warnings.
4187 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4189 * errout.adb: On anything but an expression First_Node returns its
4192 2011-08-02 Pascal Obry <obry@adacore.com>
4194 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
4196 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
4198 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
4199 Set the associated loop as the related expression of internally
4201 * exp_ch7.adb (Is_Container_Cursor): New routine.
4202 (Wrap_Transient_Declaration): Supress the finalization of the list
4203 controller when the declaration denotes a container cursor.
4205 2011-08-02 Yannick Moy <moy@adacore.com>
4207 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
4209 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
4210 expression is a simple expression. This check cannot be performed in
4211 the semantics, so just drop it.
4212 (P_Index_Or_Discriminant_Constraint): move check that the index or
4213 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
4214 semantics. Other cases were previously checked in the semantics.
4215 * par-ch4.adb (P_Name): move checks that a selector name is not
4216 character literal or an operator symbol to Find_Selected_Component in
4218 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
4219 declarations are not placed after later declarations in a separate
4220 procedure in Sem_Util (possibly not the best choice?), to be used both
4221 during parsing, for Ada 83 mode, and during semantic analysis, for
4223 * par-endh.adb (Check_End): move check that end label is not missing
4224 to Process_End_Label in the semantics
4225 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
4226 the special case for SPARK restriction
4227 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
4228 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
4229 parameter Force to issue the error message even on internal node (used
4230 for generated end label). Call Check_Restriction to check when an error
4231 must be issued. In SPARK mode, issue an error message even if the
4232 restriction is not set.
4233 (Check_Restriction): new procedure with an additional out parameter to
4234 inform the caller that a message has been issued
4235 * sem_aggr.adb: Minor modification of message
4236 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
4237 instead of issuing an error message directly
4238 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
4239 declarations are not placed after later declarations, by calling
4240 Check_Later_Vs_Basic_Declarations
4241 (Analyze_Subtype_Declaration): move here the check that an index or
4242 discriminant constraint must be a subtype mark. Change the check that
4243 a subtype of String must start at one so that it works on subtype marks.
4244 * sem_ch4.adb (Analyze_Call): move here the check that a named
4245 association cannot follow a positional one in a call
4246 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
4247 instead of issuing an error message directly
4248 * sem_ch8.adb (Find_Selected_Component): move here the check that a
4249 selector name is not a character literal or an operator symbol. Move
4250 here the check that the prefix of an expanded name cannot be a
4251 subprogram or a loop statement.
4252 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
4253 procedure called from parsing and semantics to check that basic
4254 declarations are not placed after later declarations
4255 (Process_End_Label): move here the check that end label is not missing
4257 2011-08-02 Arnaud Charlet <charlet@adacore.com>
4259 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
4260 representation clause in codepeer mode, since it confuses CodePeer and
4261 does not bring useful info.
4263 2011-08-02 Ed Falis <falis@adacore.com>
4265 * init.c: initialize fp hw on MILS.
4267 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4269 * errout.adb (First_Node): for bodies, return the node itself (small
4270 optimization). For other nodes, do not check source_unit if the node
4271 comes from Standard.
4273 2011-08-02 Robert Dewar <dewar@adacore.com>
4275 * exp_ch3.adb: Minor comment additions.
4276 * sem_ch13.adb: Minor reformatting.
4278 2011-08-02 Pascal Obry <obry@adacore.com>
4280 * make.adb, makeutl.adb: Removes some superfluous directory separator.
4282 2011-08-02 Robert Dewar <dewar@adacore.com>
4284 * sem_attr.adb: Minor reformatting.
4286 2011-08-02 Robert Dewar <dewar@adacore.com>
4288 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
4289 (Has_Default_Component_Value): Removed
4290 * einfo.ads Comment updates
4291 (Has_Default_Aspect): Replaces Has_Default_Value
4292 (Has_Default_Component_Value): Removed
4294 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
4296 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
4297 (Get_Simple_Init_Val): Handle Default_Value aspect
4298 (Needs_Simple_Initialization): Handle Default_Value aspect
4299 * exp_ch3.ads: Needs_Simple_Initialization
4300 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
4301 * par-prag.adb (Pragma_Default[_Component]Value) Removed
4303 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
4304 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
4305 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
4307 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4309 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
4310 package containing iteration primitives.
4311 exp_ch5.adb (Expand_Iterator_Loop): ditto.
4313 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4315 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
4316 "of", pre-analyze expression in case it is a function call with
4317 finalization actions that must be placed ahead of the loop.
4318 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
4319 on an Ada2012 iterator, insert them ahead of the rewritten loop.
4321 2011-08-02 Geert Bosch <bosch@adacore.com>
4323 * cstand.adb (Create_Float_Types): Only consider C's long double for
4324 Long_Long_Float, in addition to double.
4326 2011-08-02 Robert Dewar <dewar@adacore.com>
4328 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
4329 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
4330 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
4333 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4335 * sem_attr.adb: handle properly 'Result when it is a prefix of an
4338 2011-08-02 Javier Miranda <miranda@adacore.com>
4340 * einfo.ads, einfo.adb
4341 (Original_Access_Type): Move this attribute to Node26 since there was
4342 an undocumented use of Node21 in E_Access_Subprogram_Type entities
4343 which causes conflicts and breaks the generation of the .NET compiler.
4344 (Interface_Name): Add missing documentation on JGNAT only uses of
4347 2011-08-02 Geert Bosch <bosch@adacore.com>
4349 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
4350 (Find_Back_End_Float_Type): Likewise
4351 (Create_Back_End_Float_Types): Likewise
4352 (Create_Float_Types): Likewise
4353 (Register_Float_Type): Likewise
4354 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
4355 Nlist and split out type selection in new local Find_Base_Type function.
4356 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
4358 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
4360 2011-08-02 Robert Dewar <dewar@adacore.com>
4362 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
4364 * opt.ads: Minor comment change.
4365 * sem_ch12.adb: Minor code reorganization.
4367 2011-08-02 Gary Dismukes <dismukes@adacore.com>
4369 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
4370 subtype's list of rep items to the list on the full subtype in the case
4371 where the lists are the same.
4373 2011-08-02 Geert Bosch <bosch@adacore.com>
4375 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
4376 using the one from System.Strings, which also deallocates all strings.
4378 2011-08-02 Geert Bosch <bosch@adacore.com>
4380 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
4382 * gcc-interface/Make-lang.in: Update dependencies.
4384 2011-08-02 Olivier Hainque <hainque@adacore.com>
4386 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
4389 2011-08-02 Javier Miranda <miranda@adacore.com>
4391 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
4392 associated with anonymous access to subprograms.
4394 2011-08-02 Geert Bosch <bosch@adacore.com>
4397 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
4398 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
4399 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
4400 (Add_Symbol_Definition): Move to switch-c.adb
4401 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
4402 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
4403 (Add_Symbol_Definition): Move to switch-c.adb.
4404 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
4406 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
4408 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
4409 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
4411 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
4412 (Add_Symbol_Definition): Moved from Prepcomp.
4413 * switch-c.ads: Update copyright notice. Use String_List instead of
4414 Argument_List, removing dependency on System.OS_Lib.
4416 2011-08-02 Yannick Moy <moy@adacore.com>
4418 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
4419 mode on initialization expression which does not respect SPARK
4421 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
4422 if the tree referenced by its argument represents an initialization
4423 expression in SPARK, suitable for initializing an object in an object
4426 2011-08-02 Javier Miranda <miranda@adacore.com>
4428 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
4429 internally generated access to subprogram with its associated protected
4431 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
4433 2011-08-02 Geert Bosch <bosch@adacore.com>
4435 * cstand.adb (Register_Float_Type): Print information about type to
4436 register, if the Debug_Flag_Dot_B is set.
4437 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
4438 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
4439 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
4440 with a requested precision of more than Max_Digits digits and no more
4441 than Max_Base_Digits digits, if a range specification is present and the
4442 Predefined_Float_Types list has a suitable type to derive from.
4443 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
4444 case of type completion with pragma Import
4446 (Process_Import_Predefined_Type): Processing to complete a type
4447 with pragma Import. Currently supports floating point types only.
4448 (Set_Convention_From_Pragma): Do nothing without underlying type.
4449 (Process_Convention): Guard against absence of underlying type,
4450 which may happen when importing incomplete types.
4451 (Process_Import_Or_Interface): Handle case of importing predefined
4452 types. Tweak error message.
4454 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4456 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
4457 functions to previous change. Reorganize code slightly.
4459 2011-08-02 Geert Bosch <bosch@adacore.com>
4461 * back_end.ads (Register_Type_Proc): New call back procedure type for
4462 allowing the back end to provide information about available types.
4463 (Register_Back_End_Types): New procedure to register back end types.
4464 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
4466 * cstand.adb (Back_End_Float_Types): New list for floating point types
4467 supported by the back end.
4468 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
4469 (Copy_Float_Type): New procedure to make new copies of predefined types.
4470 (Register_Float_Type): New call back procedure to populate the BEFT list
4471 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
4472 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
4473 (Create_Float_Types): New procedure to create entities for floating
4474 point types predefined in Standard, and put these and any remaining
4475 BEFTs on the Predefined_Float_Types list.
4476 * stand.ads (Predefined_Float_Types): New list for predefined floating
4477 point types that do not have declarations in package Standard.
4479 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4481 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
4482 entity node for the unit containing the parameter.
4483 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
4484 (Add_Inlined_Subprogram): Likewise.
4485 * gcc-interface/Make-lang.in: Update dependencies.
4487 2011-08-02 Thomas Quinot <quinot@adacore.com>
4489 * s-stusta.adb (Print): Make sure Pos is always initialized to a
4492 2011-08-02 Geert Bosch <bosch@adacore.com>
4494 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
4496 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4498 * sem_type.adb (Covers): Move trivial case to the top and reuse the
4499 computed value of Base_Type.
4501 2011-08-02 Yannick Moy <moy@adacore.com>
4503 * restrict.adb (Check_Restriction): issue an error for any use of
4504 class-wide, even if the No_Dispatch restriction is not set.
4505 * sem_aggr.adb: Correct typos in comments and messages in formal mode
4506 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
4507 when completing a private extension, the type named in the private part
4508 is not the same as that named in the visible part.
4509 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
4510 of an inherited primitive operations of a tagged type or type extension
4511 that returns the tagged type.
4512 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
4513 function which returns True for an implicit operation inherited by the
4514 derived type declaration for the argument type.
4515 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
4518 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4520 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
4521 Process_Bounds, to perform analysis with expansion of a range or an
4522 expression that is the iteration scheme for a loop.
4523 (Analyze_Iterator_Specification): If domain of iteration is given by a
4524 function call with a controlled result, as is the case if call returns
4525 a predefined container, ensure that finalization actions are properly
4527 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
4529 2011-08-02 Javier Miranda <miranda@adacore.com>
4531 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
4532 * gcc-interface/Make-lang.in: Update dependencies.
4534 2011-08-02 Javier Miranda <miranda@adacore.com>
4536 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
4537 determine if the analysis is performed using N or Original_Node (N).
4538 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
4539 functionality of routine Is_Variable avoids code duplication.
4540 * checks.adb (Determine_Range): Handle temporaries generated by
4541 Remove_Side_Effects.
4543 2011-08-02 Javier Miranda <miranda@adacore.com>
4545 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
4546 expansion of the condition. Required since the previous analysis was
4547 done with expansion disabled (see Resolve_Quantified_Expression) and
4548 hence checks were not inserted and record comparisons have not been
4551 2011-08-02 Ed Falis <falis@adacore.com>
4553 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
4556 2011-08-02 Bob Duff <duff@adacore.com>
4558 * opt.ads: Minor comment fix.
4560 2011-08-02 Bob Duff <duff@adacore.com>
4562 * sem_ch12.adb (Analyze_Package_Instantiation,
4563 Analyze_Subprogram_Instantiation): Turn off style checking while
4564 analyzing an instance. Whatever style checks that apply to the generic
4565 unit should apply, so it makes no sense to apply them in an instance.
4566 This was causing trouble when compiling an instance of a runtime
4567 unit that violates the -gnatyO switch.
4568 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
4569 one of the two case statements, causing spurious errors.
4571 2011-08-02 Robert Dewar <dewar@adacore.com>
4573 * uname.adb: Minor reformatting.
4574 * gnatcmd.adb: Minor reformatting.
4575 * exp_attr.adb: Minor reformatting.
4577 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4579 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
4580 No_Dispatching_Calls, do not look for the Assign primitive, because
4581 predefined primitives are not created in this case.
4583 2011-08-02 Bob Duff <duff@adacore.com>
4585 * stylesw.ads: Minor comment fixes.
4587 2011-08-02 Robert Dewar <dewar@adacore.com>
4589 * freeze.adb (Add_To_Result): New procedure.
4591 2011-08-02 Jose Ruiz <ruiz@adacore.com>
4593 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
4594 time, if the specific run-time routines for handling streams of strings
4595 are not available, use the default mechanism.
4597 2011-08-02 Arnaud Charlet <charlet@adacore.com>
4599 * s-regpat.ads: Fix typo.
4601 2011-08-02 Vincent Celier <celier@adacore.com>
4603 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
4604 not null, call it to create the in memory config project file without
4605 parsing an existing default config project file.
4607 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4609 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
4611 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4613 * sem_elim.adb: an abstract subprogram does not need an eliminate
4614 pragma for its descendant to be eliminable.
4616 2011-08-02 Ed Falis <falis@adacore.com>
4618 * init.c: revert to handling before previous checkin for VxWorks
4619 * s-intman-vxworks.adb: delete unnecessary declarations related to
4620 using Ada interrupt facilities for handling signals.
4621 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
4622 * s-intman-vxworks.ads: Import __gnat_install_handler as
4623 Initialize_Interrupts.
4624 * s-taprop-vxworks.adb: Delete Signal_Mask.
4625 (Abort_Handler): change construction of mask to unblock exception
4628 2011-08-02 Jerome Guitton <guitton@adacore.com>
4630 * a-except-2005.adb (Raise_From_Signal_Handler): Call
4631 Debug_Raise_Exception before propagation starts.
4633 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4635 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
4636 to Restriction_Check_Required.
4637 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
4638 * sem_res.adb (Resolve_Call): Likewise.
4639 * sem_attr.adb (Check_Stream_Attribute): Likewise.
4641 2011-08-02 Bob Duff <duff@adacore.com>
4643 * stylesw.ads: Update comment.
4644 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
4645 * errout.ads: Remove obsolete comment.
4647 2011-08-02 Javier Miranda <miranda@adacore.com>
4649 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
4650 (Set_Is_Safe_To_Reevaluate): new procedure.
4651 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
4652 assignment is allowed on safe-to-reevaluate variables.
4653 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
4654 temporary created to remove side effects in expressions that use
4655 the secondary stack as safe-to-reevaluate.
4656 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
4657 variables that are not true constants.
4659 2011-08-02 Robert Dewar <dewar@adacore.com>
4661 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
4662 sem_res.adb, sem_ch6.adb: Minor reformatting.
4664 2011-08-02 Jerome Guitton <guitton@adacore.com>
4666 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
4668 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4670 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
4671 not set Overridden_Operation if subprogram is an initialization
4674 2011-08-02 Yannick Moy <moy@adacore.com>
4676 * par-ch6.adb: Correct obsolete name in comments
4677 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
4678 which takes two message arguments (existing function takes one), with
4679 second message used for continuation.
4680 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
4681 block statements that originate from a source block statement, not
4682 generated block statements
4683 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
4684 symmetry with procedure case
4685 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
4686 function to issue an error in formal mode if a package specification
4687 contains more than one tagged type or type extension.
4688 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
4689 parameters matching formals of tagged types are objects (or ancestor
4690 type conversions of objects), not general expressions. Issue an error
4691 on view conversions that are not involving ancestor conversion of an
4693 (Resolve_Type_Conversion): in formal mode, issue an error on the
4694 operand of an ancestor type conversion which is not an object
4695 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
4696 procedure so that it works also for actuals of function calls
4697 (Is_Actual_Tagged_Parameter): new function which determines if its
4698 argument is an actual parameter of a formal of tagged type in a
4700 (Is_SPARK_Object_Reference): new function which determines if the tree
4701 referenced by its argument represents an object in SPARK
4703 2011-08-02 Robert Dewar <dewar@adacore.com>
4705 * sem_ch3.adb: Minor reformatting
4706 Minor comment addition
4707 Minor error msg text change
4709 2011-08-02 Javier Miranda <miranda@adacore.com>
4711 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
4712 function. Used to be more precise when we generate a variable plus one
4713 assignment to remove side effects in the evaluation of the Bound
4715 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
4716 of the bound expression to force its re-analysis and thus expand the
4717 associated transient scope (if required). Code cleanup replacing the
4718 previous code that declared the constant entity by an invocation to
4719 routine Force_Evaluation which centralizes this work in the frontend.
4721 2011-08-02 Robert Dewar <dewar@adacore.com>
4723 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
4724 (Base_Type): Now uses improved Is_Base_Type function
4725 * einfo.ads (Base_Type): Inline this function
4727 2011-08-02 Robert Dewar <dewar@adacore.com>
4729 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
4730 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
4732 2011-08-02 Arnaud Charlet <charlet@adacore.com>
4734 * gcc-interface/Make-lang.in: Update dependencies.
4735 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
4738 2011-08-02 Yannick Moy <moy@adacore.com>
4740 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
4741 non-simple expression used in delta constraint
4742 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
4743 index constraint which is not a subtype mark
4744 * par.adb: With and use Restrict
4745 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
4746 mode on component type which is not a subtype mark and default
4747 expression on component
4748 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
4749 of string which does not have a lower index bound equal to 1
4750 (Array_Type_Declaration): issue an error in formal mode on index or
4751 component type which is not a subtype mark, and on aliased keyword on
4753 (Derived_Type_Declaration): issue an error in formal mode on interface,
4754 limited or abstract type
4755 (Record_Type_Declaration): issue an error in formal mode on interface
4756 (Record_Type_Definition): issue an error in formal mode on tagged types
4757 and type extensions not declared in the specification of a library unit
4758 package; on null non-tagged record; on variant part
4760 2011-08-02 Vincent Celier <celier@adacore.com>
4762 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
4763 not declared for qualified library project when Library_Name is not
4764 declared, but Library_Dir is.
4766 2011-08-02 Robert Dewar <dewar@adacore.com>
4768 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
4769 pragmas (affects aspects [Component_]Default_Value
4770 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
4771 component type for the resolution
4773 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4775 * einfo.adb (Base_Type): Tune implementation for speed.
4777 2011-08-02 Robert Dewar <dewar@adacore.com>
4779 * freeze.adb: Minor reformatting.
4781 2011-08-02 Thomas Quinot <quinot@adacore.com>
4783 * scos.ads: Update comments.
4785 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4787 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
4788 base type, because the parent may be a subtype of a private type whose
4789 convention is established in a private part.
4791 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
4793 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
4794 statement in a block when the expansion of the return expression has
4795 created a finalization chain.
4796 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
4797 with the parent node.
4798 Add N_Extended_Return_Statement to handle the case where a transient
4799 object declaration appears in the Return_Object_Declarations list of
4800 an extended return statement.
4802 2011-08-02 Matthew Gingell <gingell@adacore.com>
4804 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
4805 unused parameter 'name'.
4807 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4809 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
4810 inherited operation, check whether its alias, which is the source
4811 operastion that it renames, has been marked eliminated.
4813 2011-08-02 Javier Miranda <miranda@adacore.com>
4815 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
4816 in-mode parameter whose type is an access type since it can be used to
4817 modify its designated object. Enforce code that handles as safe an
4818 access type that is not access-to-constant but it is the result of a
4819 previous removal of side-effects.
4820 (Remove_Side_Effects): Minor code reorganization of cases which require
4821 no action. Done to incorporate documentation on new cases uncovered
4822 working in this ticket: no action needed if this routine was invoked
4823 too early and the nodes are not yet decorated.
4824 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
4825 to routine Remove_Side_Effects by calls to Force_Evaluation since they
4826 were issued with actuals that are implicitly provided by
4829 2011-08-02 Robert Dewar <dewar@adacore.com>
4831 * sem_ch3.adb, sem_res.adb: Minor reformatting.
4833 2011-08-02 Yannick Moy <moy@adacore.com>
4835 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
4836 to issue an error in formal mode on attribute not supported in this mode
4837 (Analyze_Attribute): issue errors on standard attributes not supported
4839 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
4840 comment, and issue error in formal mode on modulus which is not a power
4842 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
4844 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
4846 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
4847 operator on modular type (except 'not').
4849 2011-08-02 Robert Dewar <dewar@adacore.com>
4851 * gnat_rm.texi: Minor reformatting.
4853 2011-08-02 Arnaud Charlet <charlet@adacore.com>
4855 * s-osinte-linux.ads: Minor comment update and reformatting.
4856 * i-cexten.ads: Make this unit pure, as for its parent.
4857 Will allow its usage in more contexts if needed.
4859 2011-08-02 Robert Dewar <dewar@adacore.com>
4861 * s-utf_32.ads: Minor comment fix.
4863 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4865 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
4866 operation of a tagged synchronized type, handle the case where the
4867 controlling argument is overloaded.
4869 2011-08-02 Yannick Moy <moy@adacore.com>
4871 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
4872 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
4873 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
4874 SPARK mode and formal verification mode on processing SPARK restriction
4875 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
4876 requiring consistency checking.
4878 2011-08-02 Robert Dewar <dewar@adacore.com>
4880 * sem_res.adb: Minor reformatting.
4882 2011-08-02 Robert Dewar <dewar@adacore.com>
4884 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
4885 a-cforse.ads: Remove unneeded with of Ada.Containers
4886 Remove commented out pragma Inline's
4887 Move specifications of new subprograms to the actual specs
4889 2011-08-02 Yannick Moy <moy@adacore.com>
4891 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
4892 a-cforse.ads: Update comments.
4894 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4896 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
4898 2011-08-02 Robert Dewar <dewar@adacore.com>
4900 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
4901 a-cforse.ads, a-cofove.ads: Minor reformatting.
4903 2011-08-02 Claire Dross <dross@adacore.com>
4905 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
4906 a-cofove.ads: Add comments.
4908 2011-08-02 Yannick Moy <moy@adacore.com>
4910 * gnat_rm.texi: Document formal containers.
4912 2011-08-02 Emmanuel Briot <briot@adacore.com>
4914 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
4917 2011-08-02 Robert Dewar <dewar@adacore.com>
4919 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
4922 2011-08-02 Robert Dewar <dewar@adacore.com>
4924 * aspects.adb: New aspects Default_Value and Default_Component_Value
4925 New format of Aspect_Names table checks for omitted entries
4926 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
4927 handling of boolean aspects for derived types.
4928 New aspects Default_Value and Default_Component_Value
4929 New format of Aspect_Names table checks for omitted entries
4930 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
4931 (Has_Default_Value): New flag
4932 (Has_Default_Component_Value): New flag
4933 (Has_Default_Value): New flag
4934 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
4936 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
4937 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
4938 Default_Value and Default_Component_Value
4939 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
4940 New aspects Default_Value and Default_Component_Value
4941 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
4942 * sprint.adb: Print N_Aspect_Specification node when called from gdb
4944 2011-08-02 Vincent Celier <celier@adacore.com>
4946 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
4947 inherit library kind.
4949 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4951 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
4954 2011-08-02 Robert Dewar <dewar@adacore.com>
4956 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
4958 2011-08-02 Yannick Moy <moy@adacore.com>
4960 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
4962 2011-08-02 Robert Dewar <dewar@adacore.com>
4964 * impunit.adb: Add comment.
4966 2011-08-02 Yannick Moy <moy@adacore.com>
4968 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
4969 qualification of aggregates in formal mode
4970 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
4972 (Resolve_Aggregate): complete the test that an aggregate is adequately
4973 qualified in formal mode
4975 2011-08-02 Pascal Obry <obry@adacore.com>
4977 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
4978 * mlib-prj.adb: Supress warning when compiling binder generated file.
4979 (Build_Library): Supress all warnings when compiling the binder
4982 2011-08-02 Yannick Moy <moy@adacore.com>
4984 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
4986 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
4987 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
4988 Add with/use clauses to make Check_Formal_Restriction visible
4990 2011-08-02 Ed Schonberg <schonberg@adacore.com>
4992 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
4993 in-parameters when type of the generic formal is private in the generic
4994 spec and non-private in the body.
4996 2011-08-02 Claire Dross <dross@adacore.com>
4998 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
4999 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
5000 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
5001 * impunit.adb, Makefile.rtl: Take new files into account.
5003 2011-08-02 Robert Dewar <dewar@adacore.com>
5005 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
5006 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
5008 2011-08-02 Yannick Moy <moy@adacore.com>
5010 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
5012 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
5013 matching static array bounds, taking into account the special case of
5015 * sem_ch3.adb: Typo in comment.
5017 2011-08-02 Yannick Moy <moy@adacore.com>
5019 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
5020 which issues an error in formal mode if its argument node is originally
5022 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
5023 has a discriminant specification so that it does not include the case
5025 (Derived_Type_Declaration): move here the test that a derived type has a
5026 discriminant specification
5027 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
5028 first element of a component association before accessing its choices
5029 (presence of component association is not enough)
5030 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
5031 declaration is a library item before accessing the next element in a
5032 list, as library items are not member of lists
5033 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
5034 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
5035 Check_Formal_Restriction whenever possible.
5037 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5039 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
5040 reference when needed.
5042 2011-08-02 Bob Duff <duff@adacore.com>
5044 * gnat_ugn.texi: Fix typo.
5046 2011-08-02 Vincent Celier <celier@adacore.com>
5048 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
5049 archive file name. Do not use the full path name of archives for Open
5052 2011-08-02 Robert Dewar <dewar@adacore.com>
5054 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
5055 Analyze_Aspect_Specifications
5057 (Analyze_Aspect_Specifications): New handling for boolean aspects
5058 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
5059 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
5060 sequence for Analyze_Aspect_Specifications
5061 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
5062 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
5064 2011-08-02 Robert Dewar <dewar@adacore.com>
5066 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
5067 aspects, since these no longer exist.
5069 2011-08-02 Robert Dewar <dewar@adacore.com>
5071 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
5072 semicolon, do not try to see if there are aspects following it.
5073 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
5076 2011-08-02 Robert Dewar <dewar@adacore.com>
5078 * sem_ch8.adb, aspects.ads: Minor reformatting.
5080 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5082 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
5083 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
5085 (Analyze_Aspect_Specifications): ...here. Call above procedure.
5087 2011-08-02 Yannick Moy <moy@adacore.com>
5089 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
5090 mode on subprogram declaration outside of package specification, unless
5091 it is followed by a pragma Import
5092 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
5093 Access_Type_Declaration): issue error in formal mode on access type
5094 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
5096 (Analyze_Object_Declaration): issue error in formal mode on object
5097 declaration which does not respect SPARK restrictions
5098 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
5099 declaration which does not respect SPARK restrictions
5100 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
5101 error in formal mode on digits or delta constraint
5102 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
5103 decimal fixed point type
5104 (Derived_Type_Declaration): issue error in formal mode on derived type
5105 other than type extensions of tagged record types
5106 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
5107 with check on access definition
5108 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
5109 mode on protected definition.
5110 (Analyze_Task_Definition): issue error in formal mode on task definition
5112 2011-08-02 Robert Dewar <dewar@adacore.com>
5114 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
5116 2011-08-02 Javier Miranda <miranda@adacore.com>
5118 * sem_ch6.adb (Can_Override_Operator): New function.
5119 (Verify_Overriding_Indicator): Add missing code to check overriding
5120 indicator in operators. Fixes regression.
5121 (Check_Overriding_Indicator): Minor reformating after replacing the
5122 code that evaluates if the subprogram can override an operator by
5123 invocations to the above new function.
5125 (Write_Field26_Name): Add missing code to ensure that, following
5126 the documentation in einfo.ads, this field is not shown as attribute
5127 "Static_Initialization" on non-dispatching functions.
5129 2011-08-02 Jose Ruiz <ruiz@adacore.com>
5131 * sem_res.adb (Resolve_Call): A call to
5132 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
5133 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
5134 i.e., when the second parameter is of type Time_Span.
5136 2011-08-02 Vincent Celier <celier@adacore.com>
5138 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
5139 with an archive instead of -L<library dir> -l<library name>.
5141 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5143 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
5144 mark the base types In_Use in addition to making the operations
5147 2011-08-02 Ed Falis <falis@adacore.com>
5149 * init.c: add and setup __gnat_signal_mask for the exception signals
5150 * s-inmaop-vxworks.adb: new file.
5151 * s-intman-vxworks.adb: remove unnecessary initializations and
5153 * s-intman-vxworks.ads: remove unnecessary variable
5154 * s-taprop-vxworks.adb: simplify signal initialization
5156 2011-08-02 Robert Dewar <dewar@adacore.com>
5158 * sem_ch8.adb: Minor code reorganization, comment updates.
5160 2011-08-02 Robert Dewar <dewar@adacore.com>
5162 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
5163 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
5165 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
5166 (Matching_Static_Array_Bounds): Moved here from Sem_Res
5168 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5170 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
5171 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
5172 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
5173 use_type_clauses, to handle more efficiently use_type and use_all_type
5175 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
5176 Ada2012 Use_All_Type clause.
5177 (Use_Class_Wide_Operations): new procedure.
5179 2011-08-02 Robert Dewar <dewar@adacore.com>
5181 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
5182 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
5183 expression to expression function.
5185 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5187 * sem_ch4.adb: transform simple Ada2012 membership into equality only
5188 if types are compatible.
5190 2011-08-02 Yannick Moy <moy@adacore.com>
5192 * sem_res.adb (Matching_Static_Array_Bounds): new function which
5193 returns True if its argument array types have same dimension and same
5194 static bounds at each index.
5195 (Resolve_Actuals): issue an error in formal mode on actuals passed as
5196 OUT or IN OUT paramaters which are not view conversions in SPARK.
5197 (Resolve_Arithmetic_Op): issue an error in formal mode on
5198 multiplication or division with operands of fixed point types which are
5199 not qualified or explicitly converted.
5200 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
5201 Boolean or array type (except String) operands.
5202 (Resolve_Equality_Op): issue an error in formal mode on equality
5203 operators for array types other than String with non-matching static
5205 (Resolve_Logical_Op): issue an error in formal mode on logical operators
5206 for array types with non-matching static bounds. Factorize the code in
5207 Matching_Static_Array_Bounds.
5208 (Resolve_Qualified_Expression): issue an error in formal mode on
5209 qualified expressions for array types with non-matching static bounds.
5210 (Resolve_Type_Conversion): issue an error in formal mode on type
5211 conversion for array types with non-matching static bounds
5213 2011-08-02 Robert Dewar <dewar@adacore.com>
5215 * par-ch10.adb: Minor code reorganization (use Nkind_In).
5217 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5219 * par-ch9.adb: save location of entry for proper error message.
5221 2011-08-02 Javier Miranda <miranda@adacore.com>
5223 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
5224 (Use_Full_View) which permits this routine to climb through the
5225 ancestors using the full-view of private parents.
5226 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
5227 Use_Full_View to true in calls to Is_Ancestor.
5228 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
5229 true in call to Is_Ancestor.
5230 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
5231 Use_Full_View to true in call to Is_Ancestor.
5232 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
5233 call to Is_Ancestor.
5234 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
5235 Use_Full_View to true in calls to Is_Ancestor.
5236 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
5237 Make_Select_Specific_Data_Table, Register_Primitive,
5238 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
5239 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
5240 to true in call to Is_Ancestor.
5241 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
5242 Use_Full_View to true in calls to Is_Ancestor.
5244 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
5245 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
5247 2011-08-02 Robert Dewar <dewar@adacore.com>
5249 * gnat_rm.texi: Minor reformatting.
5250 * sem_prag.adb: Minor reformatting.
5252 2011-08-02 Tristan Gingold <gingold@adacore.com>
5254 * vms_data.ads: Add VMS qualifier for -gnateP.
5256 2011-08-02 Robert Dewar <dewar@adacore.com>
5258 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
5259 * par-ch7.adb (P_Package): Proper placement of aspects for package
5261 * par-endh.adb (Check_End): Ad Is_Sloc parameter
5262 (End_Statements): Add Is_Sloc parameterr
5263 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
5264 (Check_End): Ad Is_Sloc parameter
5265 (End_Statements): Add Is_Sloc parameterr
5267 2011-08-02 Vincent Celier <celier@adacore.com>
5269 * ug_words: Add VMS qualifier equivalent to -gnateP:
5270 /SYMBOL_PREPROCESSING.
5272 2011-08-02 Jose Ruiz <ruiz@adacore.com>
5274 * gnat-style.texi: For hexadecimal numeric literals the typical
5275 grouping of digits is 4 to represent 2 bytes.
5276 A procedure spec which is split into several lines is indented two
5279 2011-08-02 Yannick Moy <moy@adacore.com>
5281 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
5282 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
5283 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
5285 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
5286 choice in array aggregate
5287 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
5289 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
5290 positional and named aggregate for record, or others in record
5291 aggregate, or multiple choice in record aggregate
5292 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
5293 array operands to logical operations AND, OR and XOR do not have the
5294 same static lower and higher bounds
5295 * sem_ch5.adb, sinfo.ads: Correct typos in comments
5297 2011-08-01 Robert Dewar <dewar@adacore.com>
5299 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
5300 Replaces Last_Source_Node_In_Sequence.
5301 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
5302 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
5303 parens and blank in string (this was inconsistently implemented).
5305 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
5306 blank in string (this was inconsistently implemented).
5308 (Set_Global_Switches): Set formal mode switches appropriately
5309 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
5311 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
5312 call Set_Error_Msg_Lang to set "spark" as language name.
5313 * par.adb: Remove unnecessary call to set formal language for errout
5314 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
5315 appropriately and call Set_Error_Msg_Lang to set "spark" as language
5317 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
5318 calls to it, moved after resolution so that types are known
5319 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
5320 result of concatenation is not of type String
5321 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
5322 concatenation is not properly restricted
5323 * gnat_rm.texi: Add doc on pragma Spark_95.
5324 * gcc-interface/Makefile.in: Remove obsolete target pairs for
5325 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
5326 * gcc-interface/Make-lang.in: Update dependencies.
5328 2011-08-01 Javier Miranda <miranda@adacore.com>
5330 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
5331 condition that detects if the overridden operation must replace an
5334 2011-08-01 Javier Miranda <miranda@adacore.com>
5336 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
5337 code declarations inserted by Insert_Actions in each alternative of the
5338 N_Case_Expression node.
5340 2011-08-01 Robert Dewar <dewar@adacore.com>
5342 * sem_ch6.adb: Minor code reorganization.
5343 * sem_util.adb: Minor reformatting.
5345 2011-08-01 Pascal Obry <obry@adacore.com>
5347 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
5348 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
5350 2011-08-01 Yannick Moy <moy@adacore.com>
5352 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
5353 literal or operator symbol which is prefixed
5354 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
5355 mode on access attributes.
5356 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
5357 that concatenation operands are properly restricted in formal mode
5358 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
5359 Analyze_Concatenation_Operand. Issue an error in formal mode if the
5360 result of the concatenation has a type different from String.
5361 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
5362 Analyze_Quantified_Expression, Analyze_Slice,
5363 Analyze_Null): issue an error in formal mode on unsupported constructs
5365 (Analyze_Block_Statement): only issue error on source block statement
5366 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
5367 function which returns the last node in a list of nodes for which
5368 Comes_From_Source returns True, if any
5369 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
5370 Last_Source_Node_In_Sequence
5371 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
5372 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
5373 mode on unsupported constructs
5374 * sem_ch9.adb Do not return after issuing error in formal mode, as the
5375 rest of the actions may be needed later on since the error is marked as
5377 * sinfo.ads: Typos in comments.
5379 2011-08-01 Pascal Obry <obry@adacore.com>
5381 * projects.texi: Minor editing.
5383 2011-08-01 Yannick Moy <moy@adacore.com>
5385 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
5386 insertion character ~~
5387 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
5388 (Set_Error_Msg_Lang): new procedure which fixes the language for use
5389 with insertion character ~~
5390 (Set_Msg_Text): treat insertion character ~~
5391 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
5392 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
5393 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
5394 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
5395 errors related to the formal language restriction not serious
5396 (insertion character |).
5397 * par.adb (Par): set formal language for error messages if needed
5398 * sem_ch6.adb (Check_Missing_Return): take into account possible
5399 generated statements at the end of the function
5400 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
5401 enumeration value to define a new pragma SPARK_95
5402 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
5403 SPARK_Version): new type and variables to store the SPARK version
5405 (SPARK_Mode): return True when SPARK_Version is set
5406 * par-prag.adb: Correct indentation
5407 (Prag): take Pragma_SPARK_95 into account
5408 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
5411 2011-08-01 Robert Dewar <dewar@adacore.com>
5413 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
5414 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
5415 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
5417 2011-08-01 Pascal Obry <obry@adacore.com>
5419 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
5420 Target_Name to Get_Path call.
5421 (Parse_Single_Project): Likewise.
5422 (Post_Parse_Context_Clause): Likewise.
5423 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
5424 Call Initialise_Project_Path with the proper Target_Name.
5425 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
5427 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
5428 with the proper Target_Name.
5429 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
5431 (Parse_Project_And_Apply_Config): Likewise.
5432 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
5433 This is fine as this part of the code is supporting only native
5435 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
5436 is fine as this part of the code is supporting only native compilation.
5438 2011-08-01 Yannick Moy <moy@adacore.com>
5440 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
5441 of homonym, unless the homonym is one of the cases allowed in SPARK
5442 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
5443 package declaration occurring after a body.
5445 2011-08-01 Robert Dewar <dewar@adacore.com>
5447 * checks.adb, exp_ch4.adb: Minor reformatting.
5449 2011-08-01 Javier Miranda <miranda@adacore.com>
5451 * einfo.ads (Access_Disp_Table): Fix documentation.
5452 (Dispatch_Table_Wrappers): Fix documentation.
5454 2011-08-01 Pascal Obry <obry@adacore.com>
5456 * prj-env.adb, prj-env.ads: Minor reformatting.
5458 2011-08-01 Yannick Moy <moy@adacore.com>
5460 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
5461 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
5462 procedures out of these packages.
5463 * errout.ads, errout.adb
5464 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
5465 procedures in of this package
5466 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
5467 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
5468 on misplaced later vs initial declarations, like in Ada 83
5469 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
5470 formal mode on attribute of private type whose full type declaration
5472 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
5473 package declaration inside a package specification
5474 (Analyze_Full_Type_Declaration): issue error in formal mode on
5475 controlled type or discriminant type
5476 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
5477 user-defined operator means that it should come from the source
5478 (New_Overloaded_Entity): issue error in formal mode on overloaded
5480 * sem_ch6.ads, sem_ch13.ads: typos in comments.
5482 2011-08-01 Thomas Quinot <quinot@adacore.com>
5484 * atree.adb: Minor reformatting.
5485 * checks.adb: Minor reformatting.
5487 2011-08-01 Vincent Celier <celier@adacore.com>
5489 * s-parame-vms-ia64.ads: Fix typo in comment
5491 * s-parame-vms-restrict.ads: Removed, unused.
5493 2011-08-01 Javier Miranda <miranda@adacore.com>
5496 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
5498 (Constrain_Index): Remove side effects in the evaluation of the bounds.
5499 * sem_ch3.ads, sem_ch3.adb
5500 (Is_Constant_Bound): New extended version of the subprogram that was
5501 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
5502 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
5503 * sem_aux.ads (Constant_Value): Fix typo in comment.
5504 * checks.adb (Generate_Index_Checks): New implementation which, for
5505 array objects with constant bounds, generates the runtime check
5506 referencing the bounds of the array type. For other cases this routine
5507 provides its previous behavior obtaining such values from the array
5509 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
5511 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
5512 we cannot have semantic interpretations of the new node.
5514 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5516 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
5519 2011-08-01 Arnaud Charlet <charlet@adacore.com>
5521 * sem_ch8.adb: Minor code editing.
5522 * s-vxwext.adb: Remove trailing space.
5523 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
5524 consistency with other files.
5526 2011-08-01 Thomas Quinot <quinot@adacore.com>
5528 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
5530 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5532 * par-ch10.adb: reject parameterized expressions as compilation unit.
5533 * sem_ch4.adb: handle properly conditional expression with overloaded
5534 then_clause and no else_clause.
5536 2011-08-01 Tristan Gingold <gingold@adacore.com>
5538 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
5539 like done by System.Aux_DEC.
5540 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
5542 2011-08-01 Yannick Moy <moy@adacore.com>
5544 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
5545 missing label at end of declaration (subprogram or package)
5546 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
5547 of positional and named parameter association
5548 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
5549 Error_Msg_SP which adds a prefix to the error message giving the name
5550 of the formal language analyzed
5551 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
5552 access result type in subprogram, unconstrained array as result type,.
5553 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
5555 * sem_ch8.adb: Code clean up.
5557 2011-08-01 Javier Miranda <miranda@adacore.com>
5559 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
5560 * einfo.ads (Access_Disp_Table): Fix documentation.
5561 (Dispatch_Table_Wrappers): Fix documentation.
5562 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
5563 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
5564 to enforce the documentation of this attribute.
5565 (Set_Is_Interface): Cleanup the assertion.
5566 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
5567 the Underlying_Type entity before reading attribute Access_Disp_Table.
5568 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
5569 Locate the Underlying_Type before reading attribute Access_Disp_Table.
5570 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
5571 the Underlying_Type entity before reading attribute Access_Disp_Table.
5572 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
5573 Locate the Underlying_Type entity before reading attribute
5576 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5578 * s-poosiz.ads: Additional overriding indicators.
5580 2011-08-01 Yannick Moy <moy@adacore.com>
5582 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
5584 (Analyze_Iteration_Scheme): issue error in formal mode when loop
5585 parameter specification does not include a subtype mark.
5586 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
5587 formal mode on abstract subprogram.
5588 (Analyze_Subprogram_Specification): issue error in formal mode on
5589 user-defined operator.
5590 (Process_Formals): issue error in formal mode on access parameter and
5592 * sem_ch9.adb (Analyze_Abort_Statement,
5593 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
5594 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
5595 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
5596 Analyze_Requeue, Analyze_Selective_Accept,
5597 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
5598 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
5599 issue error in formal mode on user-defined raise statement.
5601 2011-08-01 Thomas Quinot <quinot@adacore.com>
5603 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
5604 declaration being hidden when overriding an implicit inherited
5606 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
5607 (-gnats), do not complain about a source file that contains only a
5610 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5612 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
5613 variable if already set.
5615 2011-08-01 Arnaud Charlet <charlet@adacore.com>
5617 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
5618 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
5619 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
5620 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
5621 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
5622 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
5623 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
5624 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
5625 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
5626 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
5627 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
5628 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
5629 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
5630 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
5631 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
5632 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
5633 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
5634 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
5635 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
5636 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
5637 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
5638 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
5639 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
5640 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
5641 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
5642 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
5643 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
5644 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
5645 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
5646 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
5647 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
5648 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
5649 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
5650 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
5651 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
5652 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
5653 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
5654 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
5655 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
5656 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
5657 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
5658 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
5659 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
5660 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
5661 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
5662 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
5663 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
5664 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
5665 s-osinte-mingw.ads: Update to GPLv3 run-time license.
5666 Use GNAT instead of GNARL.
5668 2011-08-01 Bob Duff <duff@adacore.com>
5670 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
5671 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
5672 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
5675 2011-08-01 Yannick Moy <moy@adacore.com>
5677 * debug.adb (d.D) reverve flag for the SPARK mode
5678 (d.E) reverve flag for SPARK generation mode
5679 (d.F) reverve flag for Why generation mode
5680 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
5681 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
5682 functions which return True when the corresponding modes are set
5683 (Formal_Language): return "spark" or "alfa" when in formal verification
5685 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
5686 Error_Msg to prefix the error message with a tag giving the formal
5688 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
5689 message with a tag giving the formal language
5690 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
5692 (Analyze_Case_Statement): issue error in formal mode on case statement
5693 with a single "others" case alternative
5694 (Analyze_Exit_Statement): issue errors in formal mode on exit
5695 statements which do not respect SPARK restrictions
5696 (Analyze_Goto_Statement): issue error in formal mode on goto statement
5697 (Check_Unreachable_Code): always issue an error (not a warning) in
5698 formal mode on unreachable code (concerns both code after an infinite
5699 loop and after an unconditional jump, both not allowed in SPARK)
5700 * sem_ch6.adb (Analyze_Return_Statement): add call to
5701 Set_Return_Present for a procedure containing a return statement
5702 (already done for functions in Analyze_Function_Return)
5703 (Analyze_Function_Return): issue error in formal mode on extended
5704 return or if return is not last statement in function
5705 (Check_Missing_Return): issue error in formal mode if function does
5706 not end with return or if procedure contains a return
5707 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
5708 function to detect if there is an inner scope of its parameter S which
5711 2011-08-01 Thomas Quinot <quinot@adacore.com>
5713 * sem_ch6.ads: Minor reformatting.
5715 2011-08-01 Javier Miranda <miranda@adacore.com>
5717 * sem_util.adb (Abstract_Interface_List): Complete condition when
5718 processing private type declarations to avoid reading unavailable
5720 (Is_Synchronized_Tagged_Type): Complete condition when processing
5721 private extension declaration nodes to avoid reading unavailable
5724 2011-08-01 Thomas Quinot <quinot@adacore.com>
5726 * sem_ch3.adb: Minor reformatting.
5728 2011-08-01 Thomas Quinot <quinot@adacore.com>
5730 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
5731 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
5732 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
5733 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
5734 for VMS, instead parametrize the common implementation with
5735 System.Parameters declarations.
5737 2011-08-01 Eric Botcazou <ebotcazou@adacore.com>
5739 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
5741 2011-08-01 Tristan Gingold <gingold@adacore.com>
5743 * seh_init.c: Fix SEH handler installation on win64.
5745 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5747 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
5748 double analysis of an anonymous access to subprogram, because it can
5749 lead to improper sharing of profiles and a back-end crash.
5751 2011-08-01 Robert Dewar <dewar@adacore.com>
5753 * make.adb, sem_ch4.adb: Minor reformatting.
5754 * gcc-interface/Make-lang.in: Update dependencies.
5755 * sem_util.adb, exp_ch5.adb: Minor reformatting.
5757 2011-08-01 Arnaud Charlet <charlet@adacore.com>
5759 * gnat_rm.texi: Fix definition of Long_Integer.
5761 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5763 * exp_aggr.adb: check limit size of static aggregate unconditionally,
5764 to prevent storage exhaustion.
5765 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
5766 finalized is a function body, insert the cleanup code before the final
5767 return statement, to prevent spurious warnings.
5768 * s-pooglo.ads: add overriding indicator.
5770 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5772 * sem_ch4.adb (Operator_Check): improve error message when both a
5773 with_clause and a use_clause are needed to make operator usage legal.
5774 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
5775 determine whether a compilation unit is visible within an other,
5776 either through a with_clause in the current unit, or a with_clause in
5777 its library unit or one one of its parents.
5779 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5781 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
5782 over an arbitrary expression of an array or container type.
5783 * lib-xref.adb: clarify comment.
5785 2011-08-01 Bob Duff <duff@adacore.com>
5787 * einfo.ads: Minor reformatting.
5788 * debug.adb: Minor comment improvement.
5790 2011-08-01 Javier Miranda <miranda@adacore.com>
5792 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
5793 consider hidden subprograms as valid candidates.
5795 2011-08-01 Arnaud Charlet <charlet@adacore.com>
5797 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
5799 2011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
5801 * gnat_ugn.texi: Fix typo.
5803 2011-08-01 Robert Dewar <dewar@adacore.com>
5805 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
5806 lib-xref.adb: Minor reformatting
5808 2011-08-01 Gary Dismukes <dismukes@adacore.com>
5810 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
5811 when to generate a call to Move_Final_List.
5812 (Has_Controlled_Parts): Remove this function.
5814 2011-08-01 Geert Bosch <bosch@adacore.com>
5816 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
5819 2011-08-01 Thomas Quinot <quinot@adacore.com>
5821 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
5822 explicit raise of a predefined exception as Comes_From_Source if the
5823 original N_Raise_Statement comes from source.
5825 2011-08-01 Robert Dewar <dewar@adacore.com>
5827 * sinfo.ads: Add comment.
5828 * sem_ch6.adb: Minor reformatting.
5830 2011-08-01 Robert Dewar <dewar@adacore.com>
5832 * freeze.adb (Freeze_Entity): Refine check for bad component size
5833 clause to avoid rejecting confirming clause when atomic/aliased present.
5835 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5837 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
5838 better determine whether an entity reference is a write.
5839 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
5841 * lib-xref.adb (Output_References): Do no suppress a read reference at
5842 the same location as an immediately preceeding modify-reference, to
5843 handle properly in-out actuals.
5845 2011-08-01 Tristan Gingold <gingold@adacore.com>
5847 * env.c (__gnat_setenv) [VMS]: Refine previous change.
5849 2011-08-01 Quentin Ochem <ochem@adacore.com>
5851 * i-cstrin.adb (New_String): Changed implementation, now uses only the
5852 heap to compute the result.
5854 2011-08-01 Robert Dewar <dewar@adacore.com>
5856 * atree.ads: Minor reformatting.
5858 2011-08-01 Emmanuel Briot <briot@adacore.com>
5860 * g-expect.adb (Get_Command_Output): Fix memory leak.
5862 2011-08-01 Geert Bosch <bosch@adacore.com>
5864 * cstand.adb (P_Float_Type): New procedure to print the definition of
5865 predefined fpt types.
5866 (P_Mixed_Name): New procedure to print a name using mixed case
5867 (Print_Standard): Use P_Float_Type for printing floating point types
5868 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
5869 precision IEEE float.
5871 2011-08-01 Thomas Quinot <quinot@adacore.com>
5873 * sem_ch3.adb: Minor reformatting.
5875 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5877 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
5878 the completion of a generic function, insert the new body rather than
5879 rewriting the original.
5881 2011-08-01 Yannick Moy <moy@adacore.com>
5883 * sinfo.ads, errout.ads: Typos in comments.
5885 2011-08-01 Robert Dewar <dewar@adacore.com>
5887 * par-endh.adb: Minor reformatting.
5889 2011-08-01 Robert Dewar <dewar@adacore.com>
5891 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
5892 (Pre_Post_Aspects): New subtype.
5893 * par-ch12.adb (P_Generic): New syntax for aspects in packages
5894 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
5895 * par-ch7.adb (P_Package): Remove Decl parameter
5896 (P_Package): Handle new syntax for aspects (before IS)
5897 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
5899 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
5900 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
5901 (P_Package): Remove Decl parameter
5902 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
5904 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
5906 * sem_util.ads, sem_util.adb (Static_Boolean): New function
5907 * sinfo.ads: Document new syntax for aspects in packages etc.
5908 * sprint.adb: Handle new syntax of aspects before IS in package
5910 2011-08-01 Thomas Quinot <quinot@adacore.com>
5912 * atree.ads: Minor reformatting.
5913 * sem_prag.adb: Minor reformatting.
5915 2011-08-01 Robert Dewar <dewar@adacore.com>
5917 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
5918 case expr alternative.
5920 2011-08-01 Ed Schonberg <schonberg@adacore.com>
5922 * sem_ch12.adb: Fix typo.
5924 2011-08-01 Geert Bosch <bosch@adacore.com>
5926 * sem_prag.adb (Check_No_Link_Name): New procedure.
5927 (Process_Import_Or_Interface): Use Check_No_Link_Name.
5928 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
5929 instead of Standard_Long_Long_Float_Size global. Preparation for
5930 eventual removal of per type constants.
5931 * exp_util.ads (Get_Stream_Size): New function returning the stream
5932 size value of subtype E.
5933 * exp_util.adb (Get_Stream_Size): Implement new function.
5934 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
5936 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
5938 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
5940 2011-08-01 Geert Bosch <bosch@adacore.com>
5942 * cstand.adb: Fix comments.
5943 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
5946 2011-08-01 Robert Dewar <dewar@adacore.com>
5948 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
5950 2011-08-01 Geert Bosch <bosch@adacore.com>
5952 * atree.ads: Fix comment.
5954 2011-08-01 Robert Dewar <dewar@adacore.com>
5956 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
5957 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
5958 * par.adb: Add with for Namet.Sp.
5959 * par-tchk.adb: Minor reformatting.
5961 2011-08-01 Vincent Celier <celier@adacore.com>
5963 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
5964 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
5965 of the init procedure of a SAL.
5966 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
5969 2011-08-01 Thomas Quinot <quinot@adacore.com>
5971 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
5974 2011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
5976 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
5978 2011-08-01 Thomas Quinot <quinot@adacore.com>
5980 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
5981 conformant with its spec (return True only for types that have
5982 an overriding Initialize primitive operation that prevents them from
5983 having preelaborable initialization).
5984 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
5985 initialization for controlled types in Ada 2005 or later mode.
5987 2011-08-01 Robert Dewar <dewar@adacore.com>
5989 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
5991 (Same_Aspect): New function.
5992 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
5993 Type_Invariant, Precondition, Postcondition.
5994 * snames.ads-tmpl: Add Name_Type_Invariant.
5996 2011-08-01 Robert Dewar <dewar@adacore.com>
5998 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
6000 (Freeze_All_Ent): Fix error in handling inherited aspects.
6001 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
6002 already analyzed, but don't skip entire processing of a declaration,
6003 that's wrong in some cases of declarations being rewritten.
6004 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
6005 Don't delay for integer, string literals
6006 Treat predicates in usual manner for delay, remove special case code,
6008 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
6009 (Build_Predicate_Function): Update saved expression in aspect
6010 (Build_Invariant_Procedure): Update saved expression in aspect
6011 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
6012 of replacement of discriminant references if the reference is simple.
6014 2011-08-01 Robert Dewar <dewar@adacore.com>
6016 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
6017 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
6018 Static_Predicate and Dynamic_Predicate.
6019 (Build_Predicate_Function): Add processing for Static_Predicate
6020 and Dynamic_Predicate.
6021 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
6022 (From_Static_Predicate): New flag
6023 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
6025 2011-08-01 Robert Dewar <dewar@adacore.com>
6027 * usage.adb: Documentation cleanup for Ada version modes in usage.
6028 * expander.adb: Minor reformatting.
6030 2011-08-01 Robert Dewar <dewar@adacore.com>
6032 * atree.ads: Minor comment fix.
6033 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
6034 a-witeio.ads, sem_prag.adb: Minor reformatting.
6036 2011-08-01 Doug Rupp <rupp@adacore.com>
6038 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
6039 pointers. Use descrip.h header file for convenience. Add some
6042 2011-08-01 Robert Dewar <dewar@adacore.com>
6044 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
6045 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
6046 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
6048 (Check_Aspect_At_End_Of_Declarations): New procedure
6049 (Analye_Aspect_Specification): Minor changes for above procedures
6050 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
6051 specification node as well.
6053 2011-08-01 Pascal Obry <obry@adacore.com>
6055 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
6056 Windows files. Use GetFilesAttributes() in this case to check for file
6057 existence instead of returning with an error code.
6059 2011-08-01 Vincent Celier <celier@adacore.com>
6061 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
6062 High is above Source length.
6064 2011-08-01 Robert Dewar <dewar@adacore.com>
6066 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
6068 2011-08-01 Robert Dewar <dewar@adacore.com>
6070 * aspects.ads (Boolean_Aspects): New subtype.
6071 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
6072 for derived types in cases where the parent type and derived type have
6074 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
6075 with aspects when parent type also has aspects.
6076 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
6077 boolean expression at this point).
6078 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
6079 accordance with final decision on the Ada 2012 feature.
6080 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
6082 2011-08-01 Matthew Heaney <heaney@adacore.com>
6084 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
6086 2011-08-01 Pascal Obry <obry@adacore.com>
6088 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
6089 Fix Replace_Slice when High is above current string size.
6090 (Replace_Slice): Fix DL computation when High is above current
6093 2011-08-01 Gary Dismukes <dismukes@adacore.com>
6095 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
6097 2011-08-01 Matthew Heaney <heaney@adacore.com>
6099 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
6102 2011-08-01 Pascal Obry <obry@adacore.com>
6104 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
6107 2011-08-01 Ed Schonberg <schonberg@adacore.com>
6109 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
6110 access to protected subprograms in generic bodies.
6111 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
6112 protected type, indicate that the convention of the subprogram is
6113 Convention_Protected, because it may be used in subsequent declarations
6114 within the protected declaration.
6116 2011-08-01 Vincent Celier <celier@adacore.com>
6118 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
6119 and "final" procedures when the name of the library is "ada", to avoid
6120 duplicate symbols "adainit" and "adafinal" in executables.
6122 2011-08-01 Ed Schonberg <schonberg@adacore.com>
6124 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
6125 quantified expression that appears within a postcondition and uses the
6126 Ada2012 'Result attribute.
6128 2011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6130 * init.c (__gnat_error_handler): Cast reason to int.
6131 (__gnat_install_handler): Explain sa_sigaction use.
6133 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
6135 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
6136 subprogram has copy-in copy-out parameters, try to promote the mode of
6137 the return type if it is passed in registers.
6139 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
6141 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
6142 left operand as addressable.
6144 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
6146 * gcc-interface/gigi.h (build_function_stub): Remove.
6147 (build_return_expr): Likewise.
6148 (convert_vms_descriptor): Declare.
6149 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
6150 (build_function_stub): Move to...
6151 * gcc-interface/utils2.c (build_return_expr): Move to...
6152 * gcc-interface/trans.c (build_function_stub): ...here.
6153 (build_return_expr): ...here.
6154 (Subprogram_Body_to_gnu): Add local variable for language_function.
6155 Disconnect the parameter attributes cache, if any, once done with it.
6156 Call end_subprog_body only after setting the end_locus.
6157 Build the stub associated with the function, if any, at the very end.
6158 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
6159 variables and streamline control flow.
6161 2011-07-23 Arnaud Charlet <charlet@adacore.com>
6164 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
6167 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6170 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
6171 Assign to act.sa_sigaction.
6172 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
6173 current->return_address to char * before arithmetic.
6175 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6177 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
6178 Correct argument types.
6179 Extract code from reason.
6180 (__gnat_install_handler): Assign to act.sa_sigaction.
6182 2011-07-21 Eric Botcazou <ebotcazou@adacore.com>
6184 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
6185 (GNAT1_OBJS): ...here.
6187 2011-07-15 Eric Botcazou <ebotcazou@adacore.com>
6190 * g-socthi-mingw.adb (Fill): Fix formatting.
6192 * gcc-interface/gigi.h: Move around comment.
6194 2011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
6197 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
6199 2011-07-14 Florian Weimer <fw@deneb.enyo.de>
6202 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
6204 2011-07-13 Eric Botcazou <ebotcazou@adacore.com>
6206 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
6207 range comparison if Pmode is SImode.
6209 2011-07-12 Laurent GUERBY <laurent@guerby.net>
6210 Eric Botcazou <ebotcazou@adacore.com>
6212 * adadecode.c: Wrap up in extern "C" block.
6213 * adadecode.h: Likewise.
6214 * adaint.c: Likewise. Remove 'const' keyword.
6215 * adaint.h: Likewise.
6217 * atree.h: Likewise.
6219 * cstreams.c: Likewise.
6223 * final.c: Likewise.
6225 * initialize.c: Likewise.
6227 * namet.h: Likewise.
6228 * nlists.h: Likewise.
6229 * raise.c: Likewise.
6230 * raise.h: Likewise.
6231 * repinfo.h: Likewise.
6232 * seh_init.c: Likewise.
6233 * targext.c: Likewise.
6234 * tracebak.c: Likewise.
6235 * uintp.h: Likewise.
6236 * urealp.h: Likewise.
6237 * xeinfo.adb: Wrap up generated C code in extern "C" block.
6238 * xsinfo.adb: Likewise.
6239 * xsnamest.adb: Likewise.
6240 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
6241 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
6242 * gcc-interface/misc.c: Likewise.
6243 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
6244 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
6245 ada/targext.o here...
6246 (GNAT_ADA_OBJS): ...and not here.
6247 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
6248 (GNATBIND_OBJS): Reorder.
6250 2011-07-07 Richard Henderson <rth@redhat.com>
6252 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
6253 dwarf2out_frame_init.
6255 2011-07-07 Eric Botcazou <ebotcazou@adacore.com>
6257 * gcc-interface/misc.c (gnat_init): Tweak previous change.
6259 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6262 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
6264 2011-07-06 Richard Guenther <rguenther@suse.de>
6266 * gcc-interface/misc.c (gnat_init): Merge calls to
6267 build_common_tree_nodes and build_common_tree_nodes_2.
6268 Re-initialize boolean_false_node.
6270 2011-07-02 Eric Botcazou <ebotcazou@adacore.com>
6271 Olivier Hainque <hainque@adacore.com>
6272 Nicolas Setton <setton@adacore.com>
6274 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
6275 the type according to the ARTIFICIAL_P parameter.
6276 (create_type_decl): Likewise.
6277 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
6279 2011-07-01 Eric Botcazou <ebotcazou@adacore.com>
6281 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
6282 (gnatbind): Likewise.
6284 2011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6286 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
6288 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
6290 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
6291 local variable throughout. Remove useless call to Base_Type.
6292 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
6293 Take it also into account for the volatileness of the field. Set the
6294 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
6296 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
6298 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
6299 on a dereference built for a by-ref object if it has an address clause.
6301 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
6303 * einfo.ads (Address_Taken): Document use for the second argument of
6304 Asm_Input and Asm_Output attributes.
6305 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
6306 argument is an entity name, then set Address_Taken on it.
6307 <Attribute_Asm_Output>: Likewise.
6308 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
6309 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
6310 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
6311 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
6313 2011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
6316 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
6318 2011-06-14 Joseph Myers <joseph@codesourcery.com>
6320 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
6321 (ada/utils.o): Update dependencies.
6322 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
6323 ../../../libcpp/libcpp.a.
6324 * gcc-interface/utils.c: Include common/common-target.h.
6325 (process_attributes): Use targetm_common.have_named_sections.
6327 2011-06-07 Richard Guenther <rguenther@suse.de>
6329 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
6332 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6334 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
6335 TREE_THIS_NOTRAP flag.
6337 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6339 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
6342 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6344 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
6345 constants whose full view has discriminants specially.
6347 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6349 * gcc-interface/utils.c: Include diagnostic.h.
6350 (gnat_write_global_declarations): Output debug information for all
6351 global type declarations before finalizing the compilation unit.
6352 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
6354 2011-05-25 Jakub Jelinek <jakub@redhat.com>
6356 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
6358 2011-05-25 Kai Tietz <ktietz@redhat.com>
6360 * adaint.c (__gnat_to_canonical_file_list_next): Use array
6361 initialization instead of const/none-const pointer assignment.
6363 2011-05-24 Joseph Myers <joseph@codesourcery.com>
6365 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
6366 $(EXTRA_GNAT1_OBJS).
6367 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
6368 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
6369 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
6370 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
6371 libcommon-target.a instead of prefix.o.
6373 2011-05-21 Joseph Myers <joseph@codesourcery.com>
6376 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
6378 2011-05-20 Joseph Myers <joseph@codesourcery.com>
6380 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
6381 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
6382 instead of version.o.
6384 2011-05-18 Kai Tietz <ktietz@redhat.com>
6386 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
6387 boolean_false_node instead of integer_zero_node.
6388 (convert_with_check): Likewise.
6389 * gcc-interface/decl.c (choices_to_gnu): Likewise.
6391 2011-05-12 Eric Botcazou <ebotcazou@adacore.com>
6393 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
6394 type of the parameter is an unconstrained array, convert the actual to
6395 the type of the formal in the In Out and Out cases as well.
6397 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
6399 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
6400 call build_function_type_array or build_varargs_function_type_array
6402 (create_subprog_type): Don't call build_function_type; call
6403 build_function_type_vec instead.
6405 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
6407 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
6408 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
6409 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
6411 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
6413 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
6415 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
6416 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
6418 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
6420 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
6422 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
6424 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
6425 instead of accessing TYPE_ARG_TYPES directly.
6426 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
6428 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
6431 * gcc-interface/gigi.h (get_variant_part): Declare.
6432 * gcc-interface/decl.c (get_variant_part): Make global.
6433 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
6434 types have the same constant size, are record types and T1 has a
6435 variant part while T2 doesn't.
6437 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
6439 * gcc-interface/utils.c (begin_subprog_body): Do not call
6441 (end_subprog_body): Likewise.
6443 2011-05-04 Richard Guenther <rguenther@suse.de>
6445 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
6447 (pos_to_constructor): Likewise.
6449 2011-05-03 Nathan Froyd <froydnj@codesourcery.com>
6450 Eric Botcazou <ebotcazou@adacore.com>
6452 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
6453 of build_function_type. Adjust calls to...
6454 (build_raise_check): ...this. Do not take a void_tree parameter.
6455 Call build_function_type_list instead of build_function_type.
6456 Fix head comment and swap couple of conditional blocks.
6458 2011-04-30 Eric Botcazou <ebotcazou@adacore.com>
6460 * gnatvsn.ads (Library_Version): Bump to 4.7.
6461 (Current_Year): Bump to 2011.
6463 2011-04-29 Michael Matz <matz@suse.de>
6465 * gcc-interface/misc.c (gnat_handle_option): Set
6466 warn_maybe_uninitialized.
6468 2011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
6470 * gnat_ugn.texi (Complexity Metrics Control): Update link to
6471 the Watson/McCabe paper.
6473 2011-04-23 Jim Meyering <meyering@redhat.com>
6475 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
6477 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
6479 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
6482 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
6484 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
6486 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
6487 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
6488 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
6489 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
6490 <all>: Do not set flags on the reused DECL node coming from an alias.
6491 Set DECL_IGNORED_P on the DECL node built for subprograms if they
6492 don't need debug info here...
6493 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
6494 (gigi): Adjust calls to create_subprog_decl.
6495 (build_raise_check): Likewise.
6496 (establish_gnat_vms_condition_handler): Likewise.
6497 (Compilation_Unit_to_gnu): Likewise.
6498 (gnat_to_gnu): Likewise.
6500 2011-04-21 Eric Botcazou <ebotcazou@adacore.com>
6502 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
6503 (NO_REORDER_ADAFLAGS): New variable.
6504 (EXTRA_GNATTOOLS): Always define.
6505 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
6506 Clean up and adjust list of files compiled with special options.
6507 * gcc-interface/Make-lang.in: Likewise.
6508 (ada/decl.o): Cosmetical change.
6509 (ada/misc.o): Remove dependency on $(PLUGIN_H).
6511 2011-04-20 Jim Meyering <meyering@redhat.com>
6513 * initialize.c (__gnat_initialize): Remove useless if-before-free.
6515 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
6517 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
6518 $(CFLAGS) on the link line.
6520 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
6522 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
6523 padded type built for the return type if it is unconstrained.
6525 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
6527 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
6529 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
6531 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
6532 before calling TREE_CHAIN.
6533 * gcc-interface/misc.c (gnat_init_ts): New function.
6534 (LANG_HOOKS_INIT_TS): Define.
6536 2011-04-12 Martin Jambor <mjambor@suse.cz>
6538 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
6539 instead of cgraph_node.
6541 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
6543 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
6544 alignment on fields of the RETURN type built for the Copy-In Copy-Out
6547 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
6549 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
6550 of aggregate types that contain a placeholder.
6552 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
6554 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
6556 (handle_type_generic_attribute): Likewise.
6558 2011-04-04 Eric Botcazou <ebotcazou@adacore.com>
6561 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
6563 2011-04-04 Kai Tietz <ktietz@redhat.com>
6566 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
6569 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6571 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
6572 type case, do not strip a padding type around the array type.
6574 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6576 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
6579 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6581 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
6582 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
6583 code for -feliminate-unused-debug-types.
6584 (gnat_post_options): Likewise.
6586 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6588 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
6589 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
6592 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6594 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
6595 DECL_ARTIFICIAL flag on enumeration types.
6597 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6599 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
6600 fat pointer types artificial unconditionally.
6601 <E_Array_Subtype>: Attach the base array type as a parallel type if it
6604 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6606 * gcc-interface/gigi.h (get_dummy_type): Declare.
6607 (build_dummy_unc_pointer_types): Likewise.
6608 (finish_fat_pointer_type): Likewise.
6609 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
6610 fat pointer type has been built, complete it in place.
6611 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
6612 and thin pointers. Remove useless variable.
6613 (finish_fat_pointer_type): Make global and move to...
6614 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
6615 (get_dummy_type): New function.
6616 (build_dummy_unc_pointer_types): Likewise.
6617 (gnat_pushdecl): Propage the name to the anonymous variants only.
6618 (update_pointer_to): Only adjust the pointer types in the unconstrained
6621 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6623 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
6624 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
6625 if this is a Taft amendment type and the full declaration is available.
6626 * gcc-interface/trans.c (process_type): Likewise.
6627 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
6628 (process_freeze_entity): Likewise.
6629 * gcc-interface/utils.c (dummy_global): New static variable.
6630 (gnat_write_global_declarations): If there are types declared as used
6631 at the global level, insert them in the global hash table.
6633 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6635 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
6636 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
6637 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
6639 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
6640 flag of the type accordingly.
6641 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
6643 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6645 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
6646 finalizing types when updating the pointers to the designated type.
6647 <all>: Finalize the deferred types even if we didn't defer processing
6648 of incomplete types in this invocation.
6650 2011-04-01 Olivier Hainque <hainque@adacore.com>
6651 Nicolas Setton <setton@adacore.com>
6652 Eric Botcazou <ebotcazou@adacore.com>
6654 * gcc-interface/misc.c (gnat_descriptive_type): New function.
6655 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
6657 2011-03-28 Kai Tietz <ktietz@redhat.com>
6659 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
6661 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
6662 * system-mingw.ads (System): Change ZCX_By_Default default to True.
6664 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
6666 2011-03-28 Tristan Gingold <gingold@adacore.com>
6669 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
6670 Use ada output of gnatbind.
6671 (ada/b_gnatb.adb): Ditto.
6672 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
6673 (ada.mostlyclean, ada.stage1)
6674 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
6675 (ada.stagefeedback): Adjust.
6676 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
6677 Use ada output of gnatbind.
6678 (b_gnatm.adb): Ditto.
6679 (b_gnatl.o, b_gnatm.o): New rules.
6681 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
6683 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
6684 for the padded type built to support a specified size or alignment.
6686 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
6688 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
6689 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
6690 unconditionally to the end of the unit when the designated type is
6692 <all>: Rename local variable. Attempt to un-defer types only and do it
6693 for limited_with'ed types as well.
6694 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
6695 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
6696 consistently and remove redundant call to finalize_from_with_types.
6698 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
6700 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
6701 subprograms without a previous spec declared in the same unit.
6702 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
6703 subprograms at the end of the unit instead of at the beginning.
6704 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
6705 isn't public for the special handling of non-inline functions nested
6706 inside inline external functions.
6708 2011-03-25 Jeff Law <law@redhat.com>
6710 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
6712 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
6714 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
6715 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
6716 to compute Set_Size_Depends_On_Discriminant.
6717 (Layout_Type): Call it on array types in back-end layout mode.
6718 * sem_util.adb (Requires_Transient_Scope): Return true for array
6719 types only if the size depends on the value of discriminants.
6720 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
6721 type if the RHS is a call to a function that returns an unconstrained
6722 type with default discriminant.
6724 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
6726 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
6727 non-conversion to the nominal result type at the end.
6729 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
6731 * gcc-interface/trans.c (create_temporary): New function taken from...
6732 (create_init_temporary): ...here. Call it.
6733 (call_to_gnu): Create the temporary for the return value early, if any.
6734 Create it for a function with copy-in/copy-out parameters if there is
6735 no target; in other cases of copy-in/copy-out, use another temporary.
6736 Push the new binding level lazily. Add and rename local variables.
6738 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
6740 * gcc-interface/decl.c (validate_size): Improve comments and tweak
6742 (set_rm_size): Likewise.
6744 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
6746 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
6747 for the padded type built in order to support a specified alignment.
6748 Fix incorrect formatting.
6750 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
6753 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
6755 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
6757 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
6758 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
6759 to the end of the list. Adjust recursive call. Rename local variable.
6760 If REORDER is true, reorder components of the record type.
6761 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
6762 components_to_record and adjust the parameter list.
6764 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
6766 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
6767 disabled, use the variable for bounds of loop iteration scheme.
6769 2011-03-21 Kai Tietz <ktietz@redhat.com>
6772 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
6774 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
6776 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
6777 out whether the expression is read-only. Short-circuit placeholder
6778 case and rename a couple of local variables.
6780 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
6782 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
6783 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
6784 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
6785 (convert): Deal with conversions from a smaller form type specially.
6787 2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
6789 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
6790 its argument, except for the special -I- switch.
6792 2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
6794 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
6797 2011-02-08 Eric Botcazou <ebotcazou@adacore.com>
6799 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
6801 2011-02-03 Eric Botcazou <ebotcazou@adacore.com>
6803 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
6805 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
6806 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
6807 instead of GNAT_FORMAL. Protect the expression against multiple uses.
6808 Do not generate the check directly, instead instantiate the template
6809 check present in the descriptor.
6810 (make_descriptor_field): Move around.
6811 (build_vms_descriptor32): Build a template check in the POINTER field.
6812 (build_vms_descriptor): Remove useless suffixes.
6813 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
6815 2011-01-26 Eric Botcazou <ebotcazou@adacore.com>
6818 * targext.c: Include target files if IN_RTS is defined.
6820 2011-01-26 Richard Guenther <rguenther@suse.de>
6823 * targext.c: Include config.h.
6824 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
6827 2011-01-04 Pascal Obry <obry@adacore.com>
6828 Eric Botcazou <ebotcazou@adacore.com>
6830 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
6832 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
6834 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
6835 end-of-case on the end label and its associated gotos, if any.
6837 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
6839 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
6840 expressions of the parameter cache within the statement group of
6843 2011-01-04 Olivier Hainque <hainque@adacore.com>
6844 Eric Botcazou <ebotcazou@adacore.com>
6846 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
6847 (set_end_locus_from_node): New function.
6848 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
6849 make and the function end_locus.
6850 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
6851 for the elaboration subprogram.
6852 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
6853 set the end_locus of the expression as well.
6855 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
6858 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
6859 variables that are referenced in exception handlers volatile.
6863 Copyright (C) 2011 Free Software Foundation, Inc.
6865 Copying and distribution of this file, with or without modification,
6866 are permitted in any medium without royalty provided the copyright
6867 notice and this notice are preserved.