aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Law <law@gcc.gnu.org>1998-05-11 16:04:43 -0600
committerJeff Law <law@gcc.gnu.org>1998-05-11 16:04:43 -0600
commitfc438e2ad07c189dfe97f148205cee9d5d312352 (patch)
tree483e56aea870b1178c9c7d5229254c3934345844
parent881060d07fcd9b2d0049948c2148af3203868e19 (diff)
downloadgcc-fc438e2ad07c189dfe97f148205cee9d5d312352.zip
gcc-fc438e2ad07c189dfe97f148205cee9d5d312352.tar.gz
gcc-fc438e2ad07c189dfe97f148205cee9d5d312352.tar.bz2
[multiple changes]
Tue Mar 24 10:13:07 1998 Jason Merrill <jason@yorick.cygnus.com> * std/bastring.cc (basic_string::copy): Mark const here, too. 1998-03-23 15:59 Ulrich Drepper <drepper@cygnus.com> * std/bastring.h (basic_string::copy): Mark copy function as const. Reported by Scott Schurr <scotts@ims.com>. Bring over from devo. From-SVN: r19684
-rw-r--r--libstdc++/ChangeLog9
-rw-r--r--libstdc++/std/bastring.cc2
-rw-r--r--libstdc++/std/bastring.h2
3 files changed, 11 insertions, 2 deletions
diff --git a/libstdc++/ChangeLog b/libstdc++/ChangeLog
index 0474492..f3592ad 100644
--- a/libstdc++/ChangeLog
+++ b/libstdc++/ChangeLog
@@ -1,3 +1,12 @@
+Tue Mar 24 10:13:07 1998 Jason Merrill <jason@yorick.cygnus.com>
+
+ * std/bastring.cc (basic_string::copy): Mark const here, too.
+
+1998-03-23 15:59 Ulrich Drepper <drepper@cygnus.com>
+
+ * std/bastring.h (basic_string::copy): Mark copy function as const.
+ Reported by Scott Schurr <scotts@ims.com>.
+
Thu Mar 5 09:23:28 1998 Manfred Hollstein <manfred@s-direktnet.de>
* configure.in: Make locating frag files failsafe even for the
diff --git a/libstdc++/std/bastring.cc b/libstdc++/std/bastring.cc
index 30a2382..fca6f29 100644
--- a/libstdc++/std/bastring.cc
+++ b/libstdc++/std/bastring.cc
@@ -228,7 +228,7 @@ resize (size_type n, charT c)
template <class charT, class traits, class Allocator>
basic_string <charT, traits, Allocator>::size_type
basic_string <charT, traits, Allocator>::
-copy (charT* s, size_type n, size_type pos)
+copy (charT* s, size_type n, size_type pos) const
{
OUTOFRANGE (pos > length ());
diff --git a/libstdc++/std/bastring.h b/libstdc++/std/bastring.h
index cbc6e43..8b009a4 100644
--- a/libstdc++/std/bastring.h
+++ b/libstdc++/std/bastring.h
@@ -296,7 +296,7 @@ public:
{ resize (n, eos ()); }
void reserve (size_type) { }
- size_type copy (charT* s, size_type n, size_type pos = 0);
+ size_type copy (charT* s, size_type n, size_type pos = 0) const;
size_type find (const basic_string& str, size_type pos = 0) const
{ return find (str.data(), pos, str.length()); }