]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
char_traits.h (move): Qualify memmove with std::.
authorJeffrey Oldham <oldham@codesourcery.com>
Mon, 4 Jun 2001 15:46:03 +0000 (15:46 +0000)
committerJeffrey D. Oldham <oldham@gcc.gnu.org>
Mon, 4 Jun 2001 15:46:03 +0000 (15:46 +0000)
2001-06-04  Jeffrey Oldham  <oldham@codesourcery.com>

* include/bits/char_traits.h (move): Qualify memmove with std::.
(copy): Qualify memcpy with std::.
* testsuite/27_io/filebuf_virtuals.cc (test01): Qualify strlen and
strncmp with std::.
(test02): Likewise.
* testsuite/27_io/stringbuf_virtuals.cc (test01): Likewise.

From-SVN: r42854

libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/char_traits.h
libstdc++-v3/testsuite/27_io/filebuf_virtuals.cc
libstdc++-v3/testsuite/27_io/stringbuf_virtuals.cc

index 0fba2fe3b4656e84a2b9cdfd16721bc9ba06eba2..0abbf7387cdddc247148d6e203ed186c0c1f93e0 100644 (file)
@@ -1,3 +1,12 @@
+2001-06-04  Jeffrey Oldham  <oldham@codesourcery.com>
+
+       * include/bits/char_traits.h (move): Qualify memmove with std::.
+       (copy): Qualify memcpy with std::.
+       * testsuite/27_io/filebuf_virtuals.cc (test01): Qualify strlen and
+       strncmp with std::.
+       (test02): Likewise.
+       * testsuite/27_io/stringbuf_virtuals.cc (test01): Likewise.
+
 2001-06-04  Hans-Peter Nilsson  <hp@axis.com>
 
        * libsupc++/Makefile.am (install-glibcppinstallHEADERS,
index b98a304cba13d9a9ee0a62e04379257138b65584..73cce5172e55002a93a5abacfaa4d3d643ca6fae 100644 (file)
@@ -93,11 +93,11 @@ namespace std
 
       static char_type* 
       move(char_type* __s1, const char_type* __s2, size_t __n)
-      { return (char_type*) memmove(__s1, __s2, __n * sizeof(char_type)); }
+      { return (char_type*) std::memmove(__s1, __s2, __n * sizeof(char_type)); }
 
       static char_type* 
       copy(char_type* __s1, const char_type* __s2, size_t __n)
-      { return (char_type*) memcpy(__s1, __s2, __n * sizeof(char_type)); }
+      { return (char_type*) std::memcpy(__s1, __s2, __n * sizeof(char_type)); }
 
       static char_type* 
       assign(char_type* __s, size_t __n, char_type __a)
index 50860cba4b6b13384486295a30df81c12ee62735..bcf0503f7f4dfe12b37f5832e9b66aa1fed5b768 100644 (file)
@@ -30,12 +30,12 @@ void test01()
   bool test = true;
   char buf[512];
   const char* strlit = "how to tell a story and other essays: mark twain";
-  const size_t strlitsize = strlen(strlit);
+  const size_t strlitsize = std::strlen(strlit);
   filebuf fbuf01;
 
   fbuf01.pubsetbuf(buf, 512);
   fbuf01.sputn(strlit, strlitsize);
-  VERIFY( strncmp(strlit, buf, strlitsize) != 0 );
+  VERIFY( std::strncmp(strlit, buf, strlitsize) != 0 );
 }
 
 void test02()
@@ -45,13 +45,13 @@ void test02()
   bool test = true;
   char buf[512];
   const char* strlit = "how to tell a story and other essays: mark twain";
-  const size_t strlitsize = strlen(strlit);
+  const size_t strlitsize = std::strlen(strlit);
   filebuf fbuf01;
   fbuf01.open("tmp", ios_base::out);
 
   fbuf01.pubsetbuf(buf, strlitsize);
   fbuf01.sputn(strlit, strlitsize);
-  VERIFY( strncmp(strlit, buf, strlitsize) == 0 );
+  VERIFY( std::strncmp(strlit, buf, strlitsize) == 0 );
 }
 
 main() 
index ebaf92ccaa35452c2e3268631fe88439214b378a..ff367c95e36bff97d7c93d217c103a2ab38f6896 100644 (file)
@@ -30,12 +30,12 @@ void test01()
   bool test = true;
   char buf[512];
   const char* strlit = "how to tell a story and other essays: mark twain";
-  const size_t strlitsize = strlen(strlit);
+  const size_t strlitsize = std::strlen(strlit);
   stringbuf sbuf(ios_base::out);
 
   sbuf.pubsetbuf(buf, strlitsize);
   sbuf.sputn(strlit, strlitsize);
-  VERIFY( strncmp(strlit, buf, strlitsize) != 0 );
+  VERIFY( std::strncmp(strlit, buf, strlitsize) != 0 );
 }
 
 int main()