]> gcc.gnu.org Git - gcc.git/commitdiff
a-cbhama.ads, [...] (Move): Clear Source following assignment to Target.
authorMatthew Heaney <heaney@adacore.com>
Mon, 29 Aug 2011 14:21:27 +0000 (14:21 +0000)
committerArnaud Charlet <charlet@gcc.gnu.org>
Mon, 29 Aug 2011 14:21:27 +0000 (16:21 +0200)
2011-08-29  Matthew Heaney  <heaney@adacore.com>

* a-cbhama.ads, a-cbhase.ads (Move): Clear Source following assignment
to Target.

2011-08-29  Matthew Heaney  <heaney@adacore.com>

* a-cborma.ads, a-cborse.ads (Cursor): Default-initialize all
components of record type.
* a-cborma.adb, a-cborse.adb (Move): Clear Source following assignmentw
to Target.

From-SVN: r178243

gcc/ada/ChangeLog
gcc/ada/a-cbhama.adb
gcc/ada/a-cbhase.adb
gcc/ada/a-cborma.adb
gcc/ada/a-cborma.ads
gcc/ada/a-cborse.adb
gcc/ada/a-cborse.ads

index 048bdce204f2eb4d7b4b29e6271dcc7044a5bf3f..ca82e7b1b8522aae47f4e933a45c367f46d434cd 100644 (file)
@@ -1,3 +1,15 @@
+2011-08-29  Matthew Heaney  <heaney@adacore.com>
+
+       * a-cbhama.ads, a-cbhase.ads (Move): Clear Source following assignment
+       to Target.
+
+2011-08-29  Matthew Heaney  <heaney@adacore.com>
+
+       * a-cborma.ads, a-cborse.ads (Cursor): Default-initialize all
+       components of record type.
+       * a-cborma.adb, a-cborse.adb (Move): Clear Source following assignmentw
+       to Target.
+
 2011-08-29  Ed Schonberg  <schonberg@adacore.com>
 
        * a-cbhama.adb, a-cbhama.ads, a-cborma.adb, a-cborma.ads, a-cobove.adb,
index 195d07c268ebed293e8e51101f7b1b6a42b7c731..f71a9a552b0085650d89749b2bdf881ae1f65c03 100644 (file)
@@ -728,7 +728,8 @@ package body Ada.Containers.Bounded_Hashed_Maps is
            "attempt to tamper with cursors (container is busy)";
       end if;
 
-      Assign (Target => Target, Source => Source);
+      Target.Assign (Source);
+      Source.Clear;
    end Move;
 
    ----------
index e477690d997716109cf0e93d50a57d1cd3920cc9..3b85e2effefe8aabca60509633316dec6ad121aa 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                 B o d y                                  --
 --                                                                          --
---          Copyright (C) 2004-2010, Free Software Foundation, Inc.         --
+--          Copyright (C) 2004-2011, Free Software Foundation, Inc.         --
 --                                                                          --
 -- 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- --
@@ -925,7 +925,8 @@ package body Ada.Containers.Bounded_Hashed_Sets is
            "attempt to tamper with cursors (container is busy)";
       end if;
 
-      Assign (Target => Target, Source => Source);
+      Target.Assign (Source);
+      Source.Clear;
    end Move;
 
    ----------
index 344f11dfe14c228b8bce7bf5c2a09bfb14ec1543..c9a476508af674ea8cb662f8466cdec4f9529f67 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                 B o d y                                  --
 --                                                                          --
---          Copyright (C) 2004-2010, Free Software Foundation, Inc.         --
+--          Copyright (C) 2004-2011, Free Software Foundation, Inc.         --
 --                                                                          --
 -- 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- --
@@ -998,7 +998,8 @@ package body Ada.Containers.Bounded_Ordered_Maps is
            "attempt to tamper with cursors (container is busy)";
       end if;
 
-      Assign (Target => Target, Source => Source);
+      Target.Assign (Source);
+      Source.Clear;
    end Move;
 
    ----------
index 6be977781d463efcfa56c0301180839747bd62fe..c0c160b72f41f56681afbd348cd51af2c4ba70de 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                 S p e c                                  --
 --                                                                          --
---          Copyright (C) 2004-2010, Free Software Foundation, Inc.         --
+--          Copyright (C) 2004-2011, Free Software Foundation, Inc.         --
 --                                                                          --
 -- This specification is derived from the Ada Reference Manual for use with --
 -- GNAT. The copyright notice above, and the license provisions that follow --
@@ -264,7 +264,7 @@ private
 
    type Cursor is record
       Container : Map_Access;
-      Node      : Count_Type;
+      Node      : Count_Type := 0;
    end record;
 
    procedure Write
index 12d253c648fda82af2437cd16e293290dabc2f8b..4a4bc71d416d04bc308c326a1fa04c3a89750d23 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                 B o d y                                  --
 --                                                                          --
---          Copyright (C) 2004-2010, Free Software Foundation, Inc.         --
+--          Copyright (C) 2004-2011, Free Software Foundation, Inc.         --
 --                                                                          --
 -- 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- --
@@ -1244,7 +1244,8 @@ package body Ada.Containers.Bounded_Ordered_Sets is
            "attempt to tamper with cursors (container is busy)";
       end if;
 
-      Assign (Target => Target, Source => Source);
+      Target.Assign (Source);
+      Source.Clear;
    end Move;
 
    ----------
index f9719dcdbc63641b09ce259904448924aee862d5..24b8bdc6e934434beb94da278dcfe5ca4885768e 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                 S p e c                                  --
 --                                                                          --
---          Copyright (C) 2004-2010, Free Software Foundation, Inc.         --
+--          Copyright (C) 2004-2011, Free Software Foundation, Inc.         --
 --                                                                          --
 -- This specification is derived from the Ada Reference Manual for use with --
 -- GNAT. The copyright notice above, and the license provisions that follow --
@@ -257,7 +257,7 @@ private
 
    type Cursor is record
       Container : Set_Access;
-      Node      : Count_Type;
+      Node      : Count_Type := 0;
    end record;
 
    use Tree_Types;
This page took 0.091492 seconds and 5 git commands to generate.