Commit 80363c2f by Arnaud Charlet

[multiple changes]

2014-10-10  Robert Dewar  <dewar@adacore.com>

	* sem_ch13.adb: Minor code reorganization.

2014-10-10  Pat Rogers  <rogers@adacore.com>

	* gnat_rm.texi: Text now indicates pragma No_Run_Time is not
	for users.

2014-10-10  Vadim Godunko  <godunko@adacore.com>

	* a-coinho-shared.adb: Add minor comment.
	* a-stzmap.adb (To_Sequence): Compute size of result array.

From-SVN: r216081
parent d56f4479
2014-10-10 Robert Dewar <dewar@adacore.com>
* sem_ch13.adb: Minor code reorganization.
2014-10-10 Pat Rogers <rogers@adacore.com>
* gnat_rm.texi: Text now indicates pragma No_Run_Time is not
for users.
2014-10-10 Vadim Godunko <godunko@adacore.com>
* a-coinho-shared.adb: Add minor comment.
* a-stzmap.adb (To_Sequence): Compute size of result array.
2014-10-10 Javier Miranda <miranda@adacore.com> 2014-10-10 Javier Miranda <miranda@adacore.com>
* exp_ch3.adb (Build_Init_Procedure): Complete the condition of an * exp_ch3.adb (Build_Init_Procedure): Complete the condition of an
......
...@@ -25,6 +25,13 @@ ...@@ -25,6 +25,13 @@
-- <http://www.gnu.org/licenses/>. -- -- <http://www.gnu.org/licenses/>. --
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
-- Note: special attention must be paid to the case of simultaneous access
-- to internal shared objects and elements by difference tasks. The Reference
-- counter of internal shared object is the only component protected using
-- atomic operations; other components and elements can be modified only when
-- reference counter is equal to one (so there are no other references to this
-- internal shared object and element).
with Ada.Unchecked_Deallocation; with Ada.Unchecked_Deallocation;
package body Ada.Containers.Indefinite_Holders is package body Ada.Containers.Indefinite_Holders is
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- -- Copyright (C) 1992-2014, Free Software Foundation, Inc. --
-- -- -- --
-- GNAT is free software; you can redistribute it and/or modify it under -- -- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -570,20 +570,25 @@ package body Ada.Strings.Wide_Wide_Maps is ...@@ -570,20 +570,25 @@ package body Ada.Strings.Wide_Wide_Maps is
function To_Sequence function To_Sequence
(Set : Wide_Wide_Character_Set) return Wide_Wide_Character_Sequence (Set : Wide_Wide_Character_Set) return Wide_Wide_Character_Sequence
is is
SS : constant Wide_Wide_Character_Ranges_Access := Set.Set; SS : constant Wide_Wide_Character_Ranges_Access := Set.Set;
N : Natural := 0;
Result : Wide_Wide_String (Positive range 1 .. 2 ** 16); Count : Natural := 0;
N : Natural := 0;
begin begin
for J in SS'Range loop for J in SS'Range loop
for K in SS (J).Low .. SS (J).High loop Count :=
N := N + 1; Count + (Wide_Wide_Character'Pos (SS (J).High) -
Result (N) := K; Wide_Wide_Character'Pos (SS (J).Low) + 1);
end loop;
end loop; end loop;
return Result (1 .. N); return Result : Wide_Wide_String (1 .. Count) do
for J in SS'Range loop
for K in SS (J).Low .. SS (J).High loop
N := N + 1;
Result (N) := K;
end loop;
end loop;
end return;
end To_Sequence; end To_Sequence;
------------ ------------
......
...@@ -4748,11 +4748,9 @@ pragma No_Run_Time; ...@@ -4748,11 +4748,9 @@ pragma No_Run_Time;
@noindent @noindent
This is an obsolete configuration pragma that historically was used to This is an obsolete configuration pragma that historically was used to
setup what is now called the "zero footprint" library. It causes any set up a runtime library with no object code. It is now used only for
library units outside this basic library to be ignored. The use of internal testing. The pragma has been superseded by the reconfigurable
this pragma has been superseded by the general configurable run-time runtime capability of @code{GNAT}.
capability of @code{GNAT} where the compiler takes into account whatever
units happen to be accessible in the library.
@node Pragma No_Strict_Aliasing @node Pragma No_Strict_Aliasing
@unnumberedsec Pragma No_Strict_Aliasing @unnumberedsec Pragma No_Strict_Aliasing
......
...@@ -10706,10 +10706,11 @@ package body Sem_Ch13 is ...@@ -10706,10 +10706,11 @@ package body Sem_Ch13 is
Set_Has_Inheritable_Invariants (Typ); Set_Has_Inheritable_Invariants (Typ);
end if; end if;
-- If the full view of the type is a scalar type or array type, the -- If we have a subtype with invariants, whose base type does not have
-- implicit base type created for it has the same invariant. -- invariants, copy these invariants to the base type. This happens for
-- the case of implicit base types created for scalar and array types.
elsif Has_Invariants (Typ) and then Base_Type (Typ) /= Typ elsif Has_Invariants (Typ)
and then not Has_Invariants (Base_Type (Typ)) and then not Has_Invariants (Base_Type (Typ))
then then
Set_Has_Invariants (Base_Type (Typ)); Set_Has_Invariants (Base_Type (Typ));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment