1 2012-01-30 Pascal Obry <obry@adacore.com>
3 * prj.ads, prj.adb (For_Each_Source): Add support for skipping
4 sources coming from an encapsulated library.
6 2012-01-30 Ed Schonberg <schonberg@adacore.com>
8 * sem_ch3.adb (Process-Full_View): fix typo.
9 * sem_ch13.adb (Aalyze_Aspect_Specifications): if predicates
10 appear on a private type and the full view is available, ensure
11 existence of freeze node for full view.
12 (Build_Predicate_Function): Attach predicate function to both
13 views of a private type.
15 2012-01-30 Vincent Celier <celier@adacore.com>
17 * prj-nmsc.adb (Check_Interfaces): Compute the Lib_Interface_ALIs
18 for the project if either attribute Library_Interface or
19 Interfaces is declared.
20 (Check_Stand_Alone_Library): Use Lib_Interface_ALIs computed in
23 2012-01-30 Pascal Obry <obry@adacore.com>
25 * prj-proc.adb (Recursive_Process): Set From_Encapsulated_Lib
26 boolean value to true in the process list created by this routine.
27 * prj.ads (Project_List_Element): New field From_Encapsulated_Lib.
28 Continued work for KA06-021.
29 * prj.adb (Compute_All_Imported_Projects): Set
30 From_Encapsulated_Lib boolean flag.
32 2012-01-30 Vincent Pucci <pucci@adacore.com>
34 * sem_dim.adb (Expand_Put_Call_With_Dimension_Symbol): Minor
36 * s-diflio.ads: Minor change.
38 2012-01-30 Javier Miranda <miranda@adacore.com>
40 * exp_ch9.adb (Build_Dispatching_Requeue): Add missing call
41 to Get_Entry_Index. Required to generate code which provides
42 the correct value of Entry_Index in the target entry.
44 2012-01-30 Nicolas Roche <roche@adacore.com>
46 * system-vxworks-ppc.ads: Add pragma Linker_Options -crtbe to
47 fix issue with zcx on VxWorks5.
49 2012-01-30 Pascal Obry <obry@adacore.com>
51 * prj.ads, prj.adb (For_Every_Project_Imported): Remove
53 (For_Every_Project_Imported_Context): New generic routine with
55 * prj-nmsc.adb: Revert to use For_Every_Project_Imported Avoid
56 distributed complexity.
57 * prj-env.adb, prj-conf.adb, makeutl.adb, gnatcmd.adb: Ditto.
59 2012-01-30 Thomas Quinot <quinot@adacore.com>
61 * exp_aggr.adb (Expand_Record_Aggregate): After creating the
62 _parent aggregate for an extension aggregate, check whether it
63 requires delayed (top-down) expansion.
65 2012-01-30 Vincent Pucci <pucci@adacore.com>
67 * sem_dim.adb (Expand_Put_Call_With_Dimension_Symbol): Rewritten.
68 * snames.ads-tmpl: Name_Item and Name_Symbols added.
69 * s-diflio.adb, s-diflio.ads, s-diinio.adb, s-diinio.ads: Rename
70 and change the position of parameter Symbols in every Put routine.
71 * s-dimmks.ads: Convert long float type Mks_Type into long
73 * s-llflex.ads: Modifications in comments.
75 2012-01-30 Hristian Kirtchev <kirtchev@adacore.com>
77 * sem_ch12.adb (Earlier): Do not use the
78 top level source locations of the two input nodes.
80 2012-01-30 Robert Dewar <dewar@adacore.com>
82 * einfo.ads, sem_prag.adb, sem_attr.adb, aspects.ads,
83 sem_cat.adb, sem_aggr.adb, exp_aggr.adb: Minor reformatting.
85 2012-01-30 Robert Dewar <dewar@adacore.com>
87 * a-cdlili.adb, a-cidlli.adb, a-cbdlli.adb: Minor reformatting.
89 2012-01-30 Olivier Hainque <hainque@adacore.com>
91 * sigtramp-ppcvxw.c (CFI_COMMON_REGS): Add rule for r1 back +
94 2012-01-30 Thomas Quinot <quinot@adacore.com>
96 * gnat_rm.texi, sem_dist.adb, sem_dist.ads, einfo.ads, sem_prag.adb,
97 sem_ch12.adb, sem_attr.adb, aspects.adb, aspects.ads, par-prag.adb,
98 sem_cat.adb, snames.ads-tmpl (Sem_Dist.Is_Valid_Remote_Object_Type):
99 New subprogram (extracted from
100 Sem_Cat.Validate_Remote_Access_Object_Type_Declaration).
101 (Einfo.Is_Remote_Types): Now applies to generic types. Update
102 documentation accordingly.
103 (Sem_Ch12.Analyze_Associations): A RACW type is acceptable as
104 actual for a formal type to which a pragma Remote_Access_Type
106 (Aspects, Par.Prag, Sem_Prag): Support for new pramga/aspect
108 (Sem_Attr.Analyze_Attribute, case Stub_Type): Attribute can
109 be applied to a generic type if pragma Remote_Access_Type
110 applies, in which case the type of the attribute is
111 System.Partition_Interface.RACW_Stub_Type.
113 2012-01-27 Eric Botcazou <ebotcazou@adacore.com>
115 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Do not set
116 an alignment on fields of the RETURN type built for the CICO mechanism.
118 2012-01-27 Eric Botcazou <ebotcazou@adacore.com>
120 * gcc-interface/trans.c (gnat_to_gnu): Avoid making a SAVE_EXPR for
121 a call to a function that returns an unconstrained type with default
122 discriminant. Similarly, avoid doing the conversion to the nominal
123 result type in this case.
125 2012-01-27 Eric Botcazou <ebotcazou@adacore.com>
127 * gcc-interface/ada-tree.h (DECL_ALIASED_P): New flag.
128 * gcc-interface/decl.c (is_variable_size): Rename to...
129 (type_has_variable_size): ...this.
130 (adjust_packed): Adjust to above renaming.
131 (gnat_to_gnu_field): Set DECL_ALIASED_P on the field.
132 (field_is_artificial): New predicate.
133 (field_is_aliased): Likewise.
134 (field_has_self_size): Likewise.
135 (field_has_variable_size): Likewise.
136 (components_to_record): Record information for the final layout during
137 the first pass on fields.
138 If there is an aliased field placed after a field whose length depends
139 on discriminants, put all the fields of the latter sort, last.
141 2012-01-27 Eric Botcazou <ebotcazou@adacore.com>
143 * gcc-interface/gigi.h (get_minimal_subprog_decl): Declare.
144 * gcc-interface/decl.c (get_minimal_subprog_decl): New function.
145 * gcc-interface/trans.c (Attribute_to_gnu): Use it for the prefix of an
146 Access-like attribute in a dispatch table if the subprogram is public.
148 2012-01-27 Eric Botcazou <ebotcazou@adacore.com>
150 * gcc-interface/gigi.h (create_label_decl): Adjust.
151 * gcc-interface/utils.c (create_label_decl): Add GNAT_NODE parameter
152 and invoke gnat_pushdecl on it. Remove obsolete settings.
153 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Label>: Adjust call to
155 * gcc-interface/trans.c (gnat_to_gnu) <N_Null): Likewise. Ignore the
156 label for debugging purposes.
158 2012-01-27 Eric Botcazou <ebotcazou@adacore.com>
160 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: For an aliased
161 object with an unconstrained nominal subtype and if optimization isn't
162 enabled, create a special VAR_DECL for debugging purposes.
164 2012-01-23 Robert Dewar <dewar@adacore.com>
166 * sem_prag.ads, sem_prag.adb: Minor reformatting.
168 2012-01-23 Robert Dewar <dewar@adacore.com>
170 * sem_ch13.adb (Analyze_Aspect_Specifications): Check for
171 language defined aspect applied to renaming or formal type
172 declaration (not permitted)
174 2012-01-23 Matthew Heaney <heaney@adacore.com>
176 * a-cdlili.adb, a-cidlli.adb, a-cbdlli.adb (Vet): Replaced
177 comment with pragma Assert.
179 2012-01-23 Vincent Pucci <pucci@adacore.com>
181 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): Call
182 to Make_Aspect_For_PPC_In_Gen_Sub_Decl added in ASIS mode.
183 * sem_prag.adb, sem_prag.ads (Make_Aspect_For_PPC_In_Gen_Sub_Decl): New
184 routine. In ASIS mode, convert any PPC pragmas into aspects in generic
185 subprogram declaration in order to enable the analysis of PPC boolean
188 2012-01-23 Robert Dewar <dewar@adacore.com>
190 * sem_ch3.adb (Analyze_Object_Declaration): Properly
191 handle Current_Value for volatile variables (also propagate
192 Treat_As_Volatile from type to object).
194 2012-01-23 Hristian Kirtchev <kirtchev@adacore.com>
196 * sem_ch12.adb (Install_Body): Detect the case
197 where the enclosing context is a package with a stub body that
198 has already been replaced by the actual body. In such cases,
199 the freeze node for the enclosing context must be inserted after
202 2012-01-23 Ed Schonberg <schonberg@adacore.com>
204 * sem_prag.adb (Analyze_Pragma, case Debug): Freeze the called
205 subprogram before expanding the pragma into an if-statement with
206 a block, to ensure that when the subprogram is null its body is
207 properly generated before expansion.
209 2012-01-23 Hristian Kirtchev <kirtchev@adacore.com>
211 * sem_ch12.adb (Analyze_Associations): Alphabetize local variables and
212 constants. Rename Actual_Types to Actuals_To_Freeze. Rename Next_Formal
214 Freeze all eligible subprograms which appear as actuals in
216 (Has_Fully_Defined_Profile): New routine.
217 (Renames_Standard_Subprogram): New routine.
218 (Earlier): Add local variable N. Comment update. Do not use source
219 locations when trying to determine whether one node precedes another.
221 2012-01-23 Gary Dismukes <dismukes@adacore.com>
223 * exp_ch4.adb (Expand_Concatenate): In the case
224 where the result of a concatentation can be null, set the to
225 result have both the low and high bounds of the right operand (not
226 just the high bound, as was the case prior to this fix). Also,
227 fix the saved high bound setting (Last_Opnd_High_Bound) in the
228 empty string literal case (should have been low bound minus one,
229 rather than plus one).
231 2012-01-23 Thomas Quinot <quinot@adacore.com>
233 * scos.ads, put_scos.adb, get_scos.adb (Get_SCOs, Put_SCOs): Do not
234 omit statement SCOs for disabled pragmas.
236 2012-01-23 Matthew Heaney <heaney@adacore.com>
238 * a-cohase.ads, a-cihase.ads, a-cbhase.ads, a-coorse.ads,
239 a-ciorse.ads, a-cborse.ads, a-cohama.ads, a-cihama.ads, a-cbhama.ads,
240 a-coorma.ads, a-ciorma.ads, a-cborma.ads, a-cdlili.ads, a-cidlli.ads,
241 a-cbdlli.ads, a-convec.ads, a-coinve.ads, a-cobove.ads (Cursor'Read,
242 Cursor'Write): Declare in private part.
243 (Reference_Type'Read, Reference_Type'Write): Ditto.
244 (Constant_Reference_Type'Read, Constant_Reference_Type'Write): Ditto.
246 2012-01-23 Robert Dewar <dewar@adacore.com>
248 * a-catizo.ads, a-calend.adb, a-calend.ads, par-ch13.adb: Minor
251 2012-01-23 Ed Schonberg <schonberg@adacore.com>
253 * sem_ch6.adb (Analyze_Subprogram_Declaration): Do not set the
254 Corresponding_Body on a defaulted null formal subprogram.
255 * sem_ch12.adb (Check_Formal_Package_Instance): No check needed
256 on a defaulted formal subprogram that is a null procedure.
258 2012-01-23 Hristian Kirtchev <kirtchev@adacore.com>
260 * exp_ch9.adb: Update the comments involving pragma Implemented.
261 * sem_ch3.adb (Check_Pragma_Implemented (Entity_Id)): Add local
262 constant Subp_Alias and local variable Impl_Subp. Properly
263 handle aliases of synchronized wrappers. Code cleanup.
264 (Check_Pragma_Implemented (Entity_Id; Entity_Id)): Add
265 Name_Optional as part of the condition.
266 * sem_prag.adb (Analyze_Pragma): Add "Optional" as one of the
267 valid choices of implementation kind.
268 (Check_Arg_Is_One_Of): New routine.
269 * snames.ads-tmlp: Add Name_Optional.
271 2012-01-23 Ed Schonberg <schonberg@adacore.com>
273 * par-ch13.adb: Better error recovery in illegal aspect
276 2012-01-23 Hristian Kirtchev <kirtchev@adacore.com>
278 * a-calend.adb: Add with clause for Interfaces.C. Add constant
280 (Day_Of_Week): Call the internal UTC_Time_Offset.
281 (Split): Call the internal UTC_Time_Offset.
282 (Time_Of): Call the internal UTC_Time_Offset.
283 (Time_Zone_Operations.UTC_Time_Offset): Call internal UTC_Time_Offset.
284 (UTC_Time_Offset): New library-level routine.
285 * a-calend.ads (UTC_Time_Offset): Remove parameter
286 Is_Historic. Update related comment on usage.
287 * a-catizo.adb (UTC_Time_Offset): Removed.
288 (UTC_Time_Offset (Time)): Call Time_Zone_Operations.UTC_Time_Offset.
289 * a-caltizo.ads (UTC_Time_Offset): Removed.
290 (UTC_Time_Offset (Time)): Add back the default expression of parameter
293 2012-01-23 Robert Dewar <dewar@adacore.com>
295 * sprint.ads, sprint.adb (Sprint_Node_List): Add New_Lines parameter
296 (pg,po,ps): Make sure each entry starts on new line.
298 2012-01-23 Hristian Kirtchev <kirtchev@adacore.com>
300 * a-calend.ads, a-calend.adb: Define types int and int_Pointer. Update
301 the parameter profile of procedure localtime_tzoff and its associated
303 (Day_Of_Week): Do not treat the input date as historical
304 with respect to time zones.
305 (Split): Do not treat the input
306 date as historical with respect to time zones. (Time_Of): Do
307 not treat the input constituents as forming a historical date
308 with respect to time zones.
309 (UTC_Time_Offset): Add new formal
310 parameter Is_Historic. Add local variable Flag. Update the call
312 * a-catizo.ads, a-catizo.adb (UTC_Time_Offset): New routine.
313 (UTC_Time_Offset (Time)): Update the call to
314 Time_Zone_Operations.UTC_Time_Offset.
315 * sysdep.c (__gnat_localtime_tzoff): Update parameter
316 profile. Split the processing of offsets on Windows into two - one
317 part of historic time stamps and the other for the current time.
319 2012-01-23 Robert Dewar <dewar@adacore.com>
321 * a-calend.adb: Minor reformatting.
323 2012-01-23 Ed Schonberg <schonberg@adacore.com>
325 * exp_ch9.adb, sem_ch9.adb: Handle array of access to synchronized
326 interface in requeue statement.
328 2012-01-23 Cyrille Comar <comar@adacore.com>
330 * projects.texi: Remove references to main units and replace
331 with references to main programs to be coherent with the
334 2012-01-23 Robert Dewar <dewar@adacore.com>
336 * s-utf_32.adb: Minor reformatting.
338 2012-01-23 Vincent Celier <celier@adacore.com>
340 * snames.ads-tmpl: Minor comment addition Indicate that
341 Name_Library_Encapsulated_Options is only used in gprbuild.
343 2012-01-23 Robert Dewar <dewar@adacore.com>
345 * sem_ch10.adb (Analyze_Subunit): Properly save/restore cunit
348 2012-01-23 Ed Schonberg <schonberg@adacore.com>
350 * snames.ads-tmpl: Add Name_Synchronization.
351 * aspects.ads, aspects.adb: Add Aspect_Synchronization to
352 enumeration type and related maps.
353 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle Aspect
354 Synchronization, build corresponding pragma Implemented.
355 * sem_util.adb (Implementation_Kind): Handle both explicit and
356 implicit pragma_argument association to retrieve the given
357 synchronization mode.
359 2012-01-23 Robert Dewar <dewar@adacore.com>
361 * sem_ch10.adb, errout.adb: Minor reformatting.
363 2012-01-23 Ed Schonberg <schonberg@adacore.com>
365 * sem_res.adb (Resolve_Actuals): An actual in a call to an
366 Ada 2012 Reference function does not lead to a dangerous order
369 2012-01-23 Gary Dismukes <dismukes@adacore.com>
371 * exp_util.adb (Is_Iterated_Container): Test
372 Is_Entity_Name when searching for calls to the default iterator,
373 to avoid blowing up on indirect calls which have an explicit
374 dereference as the call name.
376 2012-01-23 Thomas Quinot <quinot@adacore.com>
378 * errout.adb (Set_Msg_Node): For an N_Expanded_Name, output
379 the complete expanded name, rather than just its Selector_Name.
381 2012-01-23 Thomas Quinot <quinot@adacore.com>
383 * a-textio.adb (Put): Rewrite one-parameter Character version to
384 just call the two-parameter one with Current_Out.
386 2012-01-23 Hristian Kirtchev <kirtchev@adacore.com>
388 * freeze.adb (Check_Current_Instance): Issue an
389 error when the prefix of 'Unchecked_Access or 'Access does not
390 denote a legal aliased view of a type.
391 (Freeze_Record_Type): Do not halt the processing of record components
392 once the Has_Controlled_Component is set as this bypasses the remaining
394 (Is_Aliased_View_Of_Type): New routine.
396 2012-01-23 Thomas Quinot <quinot@adacore.com>
398 * errout.ads, freeze.adb: Minor reformatting.
400 2012-01-23 Thomas Quinot <quinot@adacore.com>
402 * sem_ch10.adb, sem_prag.adb: Remove redundant apostrophes in error
405 2012-01-23 Olivier Hainque <hainque@adacore.com>
407 * adadecode.c (__gnat_decode): Deal with empty input early,
408 preventing potential erroneous memory access later on.
410 2012-01-21 Eric Botcazou <ebotcazou@adacore.com>
413 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: In the case of a
414 renaming, preserve the volatileness through the indirection, if any.
416 2012-01-14 Andreas Schwab <schwab@linux-m68k.org>
418 * gcc-interface/Makefile.in (OSCONS_EXTRACT): Add
421 2012-01-10 Pascal Obry <obry@adacore.com>
423 * prj-nmsc.adb (Check_Library_Attributes):
424 Kill check for object/source directories for aggregate libraries.
426 2012-01-10 Matthew Heaney <heaney@adacore.com>
428 * a-cdlili.adb, a-cdlili.ads, a-cihama.adb, a-cihama.ads, a-coinve.adb,
429 a-coinve.ads, a-ciorse.adb, a-ciorse.ads, a-coorma.adb, a-coorma.ads,
430 a-cborma.adb, a-cborma.ads, a-cidlli.adb, a-cidlli.ads, a-cimutr.adb,
431 a-cimutr.ads, a-cihase.adb, a-cihase.ads, a-cohama.adb, a-cohama.ads,
432 a-coorse.adb, a-coorse.ads, a-cbhama.adb, a-cbhama.ads, a-cborse.adb,
433 a-cborse.ads, a-comutr.adb, a-comutr.ads, a-ciorma.adb, a-cobove.adb,
434 a-ciorma.ads, a-cobove.ads, a-convec.adb, a-convec.ads, a-cohase.adb,
435 a-cohase.ads, a-cbdlli.adb, a-cbdlli.ads, a-cbmutr.adb, a-cbmutr.ads,
436 a-cbhase.adb, a-cbhase.ads (Reference, Constant_Reference): Declare
437 container parameter as aliased in/in out.
440 2012-01-10 Bob Duff <duff@adacore.com>
442 * s-os_lib.ads: Improve comment.
444 2012-01-10 Geert Bosch <bosch@adacore.com>
446 * s-gearop.adb (Forward_Eliminate): Avoid improper aliasing
449 2012-01-10 Bob Duff <duff@adacore.com>
451 * sem_intr.adb (Check_Shift): Use RM_Size instead of Esize, when
452 checking that the 'Size is correct. If the type is "mod 2**12",
453 for example, it's illegal, but Esize is the 'Object_Size, which
454 will be something like 16 or 32, so the error ('Size = 12) was
456 * gnat_rm.texi: Improve documentation of shift
457 and rotate intrinsics.
459 2012-01-10 Pascal Obry <obry@adacore.com>
461 * prj.adb (For_Every_Project_Imported): Fix
462 implementation to make sure we return each project only once
463 for aggragte libraries. It is fine to return a project twice for
464 aggregate projects, this was the case as a Project_Id is different
465 in each project tree. The new implementation use a table based on
466 the project name to ensure proper detection of duplicate project
467 in aggregate library. A new context is then created to continue
468 retrurning duplicate project for aggregate libraries.
470 2012-01-09 Eric Botcazou <ebotcazou@adacore.com>
472 * gcc-interface/trans.c (call_to_gnu): Create the temporary for the
473 return value in the variable-sized return type case if the target is
474 an array with fixed size. However, do not create it if this is the
475 expression of an object declaration.
477 2012-01-09 Eric Botcazou <ebotcazou@adacore.com>
479 * gcc-interface/trans.c (addressable_p) <COMPONENT_REF>: Fix thinko.
481 2012-01-06 Robert Dewar <dewar@adacore.com>
483 * a-wichha.ads, a-wichun.ads, a-zchhan.ads, a-zchuni.ads,
484 s-utf_32.ads: Add pragma Pure
485 * s-utf_32.adb: Suppress warnings on non-static constants (now
488 2012-01-06 Bob Duff <duff@adacore.com>
490 * s-rpc.ads (Read, Write): Add overriding indicators.
492 2012-01-06 Robert Dewar <dewar@adacore.com>
494 * gnat_rm.texi: Add documentation for conventions
495 Ada_Pass_By_Copy and Ada_Pass_By_Reference.
497 2012-01-06 Gary Dismukes <dismukes@adacore.com>
499 * a-tienio.adb (Put): Add exception message on
500 raise statements. Remove unneeded blocks and object declarations.
502 2012-01-06 Robert Dewar <dewar@adacore.com>
504 * sem_prag.adb: Minor reformatting.
506 2012-01-06 Ed Schonberg <schonberg@adacore.com>
508 * sinfo.ads, sinfo.adb (Has_Prefixed_Call): New flag to indicate
509 that a selected component within a generic unit has been resolved
510 as a prefixed call with local references.
511 * sem_ch3.adb (Is_Visible_Component): In an instance body a selected
512 component is always visible.
513 * sem_ch4.adb (Analyze_Selected_Component): If the node is a
514 prefixed call in an instance, do not look for visible components
516 * sem_ch12.adb (Reset_Entity): If a selected component has resolved
517 to a prefixed call, mark the node accordingly when prefix and
518 selector are local references.
520 2012-01-02 Eric Botcazou <ebotcazou@adacore.com>
522 * gnatvsn.ads (Current_Year): Bump to 2012.
524 Copyright (C) 2012 Free Software Foundation, Inc.
526 Copying and distribution of this file, with or without modification,
527 are permitted in any medium without royalty provided the copyright
528 notice and this notice are preserved.