mirror of git://gcc.gnu.org/git/gcc.git
re PR libstdc++/27199 (ptrdiff_t and size_t outside of namespace std)
2006-04-23 Marc Glisse <marc.glisse@normalesup.org> PR libstdc++/27199 * ext/pool_allocator.h: Add using declarations for size_t, ptrdiff_t. * ext/bitmap_allocator.h: Likewise; qualify with std::. * ext/new_allocator.h: Likewise. * ext/malloc_allocator.h: Likewise. * ext/array_allocator.h: Likewise. * ext/mt_allocator.h: Likewise. * ext/functional: Likewise for size_t. * ext/debug_allocator.h: Likewise. * bits/char_traits.h: Qualify with std:: size_t. * debug/hash_multimap.h: Likewise. From-SVN: r113195
This commit is contained in:
parent
c9379bf062
commit
05a2763ef3
|
@ -1,3 +1,17 @@
|
||||||
|
2006-04-23 Marc Glisse <marc.glisse@normalesup.org>
|
||||||
|
|
||||||
|
PR libstdc++/27199
|
||||||
|
* ext/pool_allocator.h: Add using declarations for size_t, ptrdiff_t.
|
||||||
|
* ext/bitmap_allocator.h: Likewise; qualify with std::.
|
||||||
|
* ext/new_allocator.h: Likewise.
|
||||||
|
* ext/malloc_allocator.h: Likewise.
|
||||||
|
* ext/array_allocator.h: Likewise.
|
||||||
|
* ext/mt_allocator.h: Likewise.
|
||||||
|
* ext/functional: Likewise for size_t.
|
||||||
|
* ext/debug_allocator.h: Likewise.
|
||||||
|
* bits/char_traits.h: Qualify with std:: size_t.
|
||||||
|
* debug/hash_multimap.h: Likewise.
|
||||||
|
|
||||||
2006-04-23 Paolo Carlini <pcarlini@suse.de>
|
2006-04-23 Paolo Carlini <pcarlini@suse.de>
|
||||||
|
|
||||||
* docs/html/ext/lwg-active.html, lwg-defects.html: Import Revision 42.
|
* docs/html/ext/lwg-active.html, lwg-defects.html: Import Revision 42.
|
||||||
|
|
|
@ -148,7 +148,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
char_traits<_CharT>::
|
char_traits<_CharT>::
|
||||||
compare(const char_type* __s1, const char_type* __s2, std::size_t __n)
|
compare(const char_type* __s1, const char_type* __s2, std::size_t __n)
|
||||||
{
|
{
|
||||||
for (size_t __i = 0; __i < __n; ++__i)
|
for (std::size_t __i = 0; __i < __n; ++__i)
|
||||||
if (lt(__s1[__i], __s2[__i]))
|
if (lt(__s1[__i], __s2[__i]))
|
||||||
return -1;
|
return -1;
|
||||||
else if (lt(__s2[__i], __s1[__i]))
|
else if (lt(__s2[__i], __s1[__i]))
|
||||||
|
|
|
@ -181,7 +181,7 @@ namespace __debug
|
||||||
erase(const key_type& __key)
|
erase(const key_type& __key)
|
||||||
{
|
{
|
||||||
std::pair<iterator, iterator> __victims = this->equal_range(__key);
|
std::pair<iterator, iterator> __victims = this->equal_range(__key);
|
||||||
size_t __num_victims = 0;
|
std::size_t __num_victims = 0;
|
||||||
while (__victims.first != __victims.second)
|
while (__victims.first != __victims.second)
|
||||||
{
|
{
|
||||||
this->erase(__victims.first++);
|
this->erase(__victims.first++);
|
||||||
|
|
|
@ -41,6 +41,9 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
|
using std::ptrdiff_t;
|
||||||
|
|
||||||
/// @brief Base class.
|
/// @brief Base class.
|
||||||
template<typename _Tp>
|
template<typename _Tp>
|
||||||
class array_allocator_base
|
class array_allocator_base
|
||||||
|
|
|
@ -71,6 +71,9 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
|
using std::ptrdiff_t;
|
||||||
|
|
||||||
#if defined __GTHREADS
|
#if defined __GTHREADS
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
|
@ -238,8 +241,8 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
typedef _Tp* pointer;
|
typedef _Tp* pointer;
|
||||||
typedef _Tp& reference;
|
typedef _Tp& reference;
|
||||||
typedef const _Tp& const_reference;
|
typedef const _Tp& const_reference;
|
||||||
typedef std::size_t size_type;
|
typedef size_t size_type;
|
||||||
typedef std::ptrdiff_t difference_type;
|
typedef ptrdiff_t difference_type;
|
||||||
typedef pointer iterator;
|
typedef pointer iterator;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@ -396,7 +399,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
struct __mv_iter_traits<_Tp*>
|
struct __mv_iter_traits<_Tp*>
|
||||||
{
|
{
|
||||||
typedef _Tp value_type;
|
typedef _Tp value_type;
|
||||||
typedef std::ptrdiff_t difference_type;
|
typedef ptrdiff_t difference_type;
|
||||||
};
|
};
|
||||||
|
|
||||||
enum
|
enum
|
||||||
|
@ -865,8 +868,8 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
class bitmap_allocator : private free_list
|
class bitmap_allocator : private free_list
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
typedef std::size_t size_type;
|
typedef size_t size_type;
|
||||||
typedef std::ptrdiff_t difference_type;
|
typedef ptrdiff_t difference_type;
|
||||||
typedef _Tp* pointer;
|
typedef _Tp* pointer;
|
||||||
typedef const _Tp* const_pointer;
|
typedef const _Tp* const_pointer;
|
||||||
typedef _Tp& reference;
|
typedef _Tp& reference;
|
||||||
|
|
|
@ -52,6 +52,8 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief A meta-allocator with debugging bits, as per [20.4].
|
* @brief A meta-allocator with debugging bits, as per [20.4].
|
||||||
*
|
*
|
||||||
|
|
|
@ -67,6 +67,7 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
using std::unary_function;
|
using std::unary_function;
|
||||||
using std::binary_function;
|
using std::binary_function;
|
||||||
using std::mem_fun1_t;
|
using std::mem_fun1_t;
|
||||||
|
|
|
@ -40,6 +40,9 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
|
using std::ptrdiff_t;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief An allocator that uses malloc.
|
* @brief An allocator that uses malloc.
|
||||||
*
|
*
|
||||||
|
|
|
@ -42,6 +42,9 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
|
using std::ptrdiff_t;
|
||||||
|
|
||||||
typedef void (*__destroy_handler)(void*);
|
typedef void (*__destroy_handler)(void*);
|
||||||
|
|
||||||
/// @brief Base class for pool object.
|
/// @brief Base class for pool object.
|
||||||
|
|
|
@ -39,6 +39,9 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
|
using std::ptrdiff_t;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief An allocator that uses global new, as per [20.4].
|
* @brief An allocator that uses global new, as per [20.4].
|
||||||
*
|
*
|
||||||
|
|
|
@ -56,6 +56,9 @@
|
||||||
|
|
||||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||||
|
|
||||||
|
using std::size_t;
|
||||||
|
using std::ptrdiff_t;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Base class for __pool_alloc.
|
* @brief Base class for __pool_alloc.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue