Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r58285 - sandbox/memory/boost/memory/container
From: xushiweizh_at_[hidden]
Date: 2009-12-10 22:11:32


Author: xushiwei
Date: 2009-12-10 22:11:31 EST (Thu, 10 Dec 2009)
New Revision: 58285
URL: http://svn.boost.org/trac/boost/changeset/58285

Log:
t
Text files modified:
   sandbox/memory/boost/memory/container/dcl_list.hpp | 8 ++++----
   1 files changed, 4 insertions(+), 4 deletions(-)

Modified: sandbox/memory/boost/memory/container/dcl_list.hpp
==============================================================================
--- sandbox/memory/boost/memory/container/dcl_list.hpp (original)
+++ sandbox/memory/boost/memory/container/dcl_list.hpp 2009-12-10 22:11:31 EST (Thu, 10 Dec 2009)
@@ -242,8 +242,8 @@
         }
 
 public:
- NodeT* BOOST_MEMORY_CALL first() { return (NodeT*)m_next; }
- const NodeT* BOOST_MEMORY_CALL first() const { return (const NodeT*)m_next; }
+ NodeT* BOOST_MEMORY_CALL first() { return static_cast<NodeT*>(m_next); }
+ const NodeT* BOOST_MEMORY_CALL first() const { return static_cast<const NodeT*>(m_next); }
 
         bool BOOST_MEMORY_CALL done(const NodeT* node) const
         {
@@ -257,8 +257,8 @@
         iterator BOOST_MEMORY_CALL begin() { return iterator(first()); }
         const_iterator BOOST_MEMORY_CALL begin() const { return const_iterator(first()); }
 
- iterator BOOST_MEMORY_CALL end() { return iterator((NodeT*)this); }
- const_iterator BOOST_MEMORY_CALL end() const { return const_iterator((const NodeT*)this); }
+ iterator BOOST_MEMORY_CALL end() { return iterator(static_cast<NodeT*>(this)); }
+ const_iterator BOOST_MEMORY_CALL end() const { return const_iterator(static_cast<const NodeT*>(this)); }
 };
 
 // -------------------------------------------------------------------------


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk