incubator-stdcxx-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Farid Zaripov <Far...@kyiv.vdiweb.com>
Subject [PATCH] std::swap (std::container&, std::container&) in MSVC 7.0
Date Wed, 27 Sep 2006 12:07:55 GMT
   If #defined _RWSTD_NO_PART_SPEC_OVERLOAD the functions
std::swap (std::container&, std::container&) is not defined (where 
container is vector, list, string, deque, ...).

   They may be defined the same way, as in the MSVC 7.0 STL:

class container
{
public:
     friend void swap (container& __lhs, container& __rhs)
     {
         __lhs.swap (__rhs);
     }
};

   I have been added this functions with additional test 
(etc/config/src/INLINE_FRIENDS.cpp).

   ChangeLog:
   * INLINE_FRIENDS.cpp: New file checking the inline friend functions
   * deque: Added #ifndef _RWSTD_NO_PART_SPEC_OVERLOAD/#endif around the
   function std::swap<T, A> (std::deque<T, A>&, std::deque<T, A>&);
   [_RWSTD_NO_PART_SPEC_OVERLOAD && !_RWSTD_NO_INLINE_FRIENDS]:
   Added function std::swap (std::deque&, std::deque&)
   * list [_RWSTD_NO_PART_SPEC_OVERLOAD && !_RWSTD_NO_INLINE_FRIENDS]:
   Added function std::swap (std::list&, std::list&)
   * map [_RWSTD_NO_PART_SPEC_OVERLOAD && !_RWSTD_NO_INLINE_FRIENDS]:
   Added functions std::swap (std::map&, std::map&) and
   std::swap (std::multimap&, std::multimap&)
   * set [_RWSTD_NO_PART_SPEC_OVERLOAD && !_RWSTD_NO_INLINE_FRIENDS]:
   Added functions std::swap (std::set&, std::set&) and
   std::swap (std::multiset&, std::multiset&)
   * string [_RWSTD_NO_PART_SPEC_OVERLOAD && !_RWSTD_NO_INLINE_FRIENDS]:
   Added function std::swap (std::string&, std::string&)
   * vector [_RWSTD_NO_PART_SPEC_OVERLOAD && !_RWSTD_NO_INLINE_FRIENDS]:
   Added functions std::swap (std::vector&, std::vector&) and
   std::swap (std::vector<bool>&, std::vector<bool>&)

Farid.

Mime
View raw message