summaryrefslogtreecommitdiff
path: root/libstdc++-v3/testsuite
diff options
context:
space:
mode:
authorpaolo <paolo@138bc75d-0d04-0410-961f-82ee72b054a4>2007-04-11 15:19:15 +0000
committerpaolo <paolo@138bc75d-0d04-0410-961f-82ee72b054a4>2007-04-11 15:19:15 +0000
commitcbb49c45ba298ef9286b850853389762b2f54e23 (patch)
tree990efb8ae32702ecec0ecea8294040b6d340f442 /libstdc++-v3/testsuite
parent516aa37deb121650b6787d53cb1831119cff3e60 (diff)
downloadgcc-cbb49c45ba298ef9286b850853389762b2f54e23.tar.gz
2007-04-11 Paolo Carlini <pcarlini@suse.de>
* include/bits/locale_facets.tcc (num_get<>::do_get(iter_type, ios_base&, ios_base::iostate&, void*&)): Fix for sizeof(void*) > sizeof(unsigned long). * testsuite/22_locale/num_get/get/char/1.cc: Fix void* test. * testsuite/22_locale/num_get/get/wchar_t/1.cc: Likewise. * testsuite/22_locale/num_put/put/char/1.cc: Tweak comment. * testsuite/22_locale/num_put/put/wchar_t/1.cc: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@123716 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/testsuite')
-rw-r--r--libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc10
-rw-r--r--libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc8
-rw-r--r--libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc3
-rw-r--r--libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc6
4 files changed, 13 insertions, 14 deletions
diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc
index 8ff9852c616..266388fcc2d 100644
--- a/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc
+++ b/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc
@@ -2,7 +2,8 @@
// 2001-11-21 Benjamin Kosnik <bkoz@redhat.com>
-// Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation
+// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007
+// Free Software Foundation
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
@@ -51,8 +52,7 @@ void test01()
double d;
long double ld1 = 6.630025e+4;
long double ld;
- void* v;
- const void* cv = &ul2;
+ void* v = 0;
// cache the num_get facet
istringstream iss;
@@ -125,12 +125,12 @@ void test01()
VERIFY( ld == 0 );
VERIFY( err == goodbit );
- // const void
+ // void*
iss.str("0xbffff74c,");
iss.clear();
err = goodbit;
ng.get(iss.rdbuf(), 0, iss, err, v);
- VERIFY( &v != &cv );
+ VERIFY( v != 0 );
VERIFY( err == goodbit );
#ifdef _GLIBCXX_USE_LONG_LONG
diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc
index 4e54397db13..43cfa93df3c 100644
--- a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc
+++ b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc
@@ -2,7 +2,8 @@
// 2001-11-21 Benjamin Kosnik <bkoz@redhat.com>
-// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation
+// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007
+// Free Software Foundation
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
@@ -52,7 +53,6 @@ void test01()
long double ld1 = 6.630025e+4;
long double ld;
void* v;
- const void* cv = &ul2;
// cache the num_get facet
wistringstream iss;
@@ -124,12 +124,12 @@ void test01()
VERIFY( ld == 0 );
VERIFY( err == goodbit );
- // const void
+ // void*
iss.str(L"0xbffff74c,");
iss.clear();
err = goodbit;
ng.get(iss.rdbuf(), 0, iss, err, v);
- VERIFY( &v != &cv );
+ VERIFY( v != 0 );
VERIFY( err == goodbit );
#ifdef _GLIBCXX_USE_LONG_LONG
diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc
index 1ea37764835..36c6307bbb0 100644
--- a/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc
+++ b/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc
@@ -65,7 +65,6 @@ void test01()
iterator_type os_it01 = np.put(os_it00, oss, '+', b1);
result1 = oss.str();
VERIFY( result1 == "1" );
- // VERIFY( os_it00 != os_it01 );
oss.str(empty);
np.put(oss.rdbuf(), oss, '+', b0);
@@ -134,7 +133,7 @@ void test01()
result1 = oss.str();
VERIFY( result1 == "0" );
- // const void
+ // const void*
oss.str(empty);
oss.clear();
np.put(oss.rdbuf(), oss, '+', cv);
diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc
index 9ff25d5ef86..f588df3497a 100644
--- a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc
+++ b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc
@@ -2,7 +2,8 @@
// 2001-11-19 Benjamin Kosnik <bkoz@redhat.com>
-// Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation
+// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007
+// Free Software Foundation
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
@@ -65,7 +66,6 @@ void test01()
iterator_type os_it01 = np.put(os_it00, oss, L'+', b1);
result1 = oss.str();
VERIFY( result1 == L"1" );
- // VERIFY( os_it00 != os_it01 );
oss.str(empty);
np.put(oss.rdbuf(), oss, L'+', b0);
@@ -134,7 +134,7 @@ void test01()
result1 = oss.str();
VERIFY( result1 == L"0" );
- // const void
+ // const void*
oss.str(empty);
oss.clear();
np.put(oss.rdbuf(), oss, L'+', cv);