summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2011-08-29 14:21:27 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2011-08-29 14:21:27 +0000
commit704880481a22c59657091bfb5b998efd989c9a5f (patch)
tree08443dfec4931ee42498fe054ec70bfa2e0a1c94
parent2a2129b6f630c9b313f8d3e5055f13eedf0f3077 (diff)
downloadgcc-704880481a22c59657091bfb5b998efd989c9a5f.tar.gz
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. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@178243 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ada/ChangeLog12
-rw-r--r--gcc/ada/a-cbhama.adb3
-rw-r--r--gcc/ada/a-cbhase.adb5
-rw-r--r--gcc/ada/a-cborma.adb5
-rw-r--r--gcc/ada/a-cborma.ads4
-rw-r--r--gcc/ada/a-cborse.adb5
-rw-r--r--gcc/ada/a-cborse.ads4
7 files changed, 27 insertions, 11 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index 048bdce204f..ca82e7b1b85 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -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,
diff --git a/gcc/ada/a-cbhama.adb b/gcc/ada/a-cbhama.adb
index 195d07c268e..f71a9a552b0 100644
--- a/gcc/ada/a-cbhama.adb
+++ b/gcc/ada/a-cbhama.adb
@@ -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;
----------
diff --git a/gcc/ada/a-cbhase.adb b/gcc/ada/a-cbhase.adb
index e477690d997..3b85e2effef 100644
--- a/gcc/ada/a-cbhase.adb
+++ b/gcc/ada/a-cbhase.adb
@@ -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;
----------
diff --git a/gcc/ada/a-cborma.adb b/gcc/ada/a-cborma.adb
index 344f11dfe14..c9a476508af 100644
--- a/gcc/ada/a-cborma.adb
+++ b/gcc/ada/a-cborma.adb
@@ -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;
----------
diff --git a/gcc/ada/a-cborma.ads b/gcc/ada/a-cborma.ads
index 6be977781d4..c0c160b72f4 100644
--- a/gcc/ada/a-cborma.ads
+++ b/gcc/ada/a-cborma.ads
@@ -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
diff --git a/gcc/ada/a-cborse.adb b/gcc/ada/a-cborse.adb
index 12d253c648f..4a4bc71d416 100644
--- a/gcc/ada/a-cborse.adb
+++ b/gcc/ada/a-cborse.adb
@@ -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;
----------
diff --git a/gcc/ada/a-cborse.ads b/gcc/ada/a-cborse.ads
index f9719dcdbc6..24b8bdc6e93 100644
--- a/gcc/ada/a-cborse.ads
+++ b/gcc/ada/a-cborse.ads
@@ -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;