Salome HOME
Merge branch 'master' into rbe/fix-boost-smart-pointers
authorRenaud Nédélec <renaud.nedelec@opencascade.com>
Wed, 2 Apr 2014 08:26:24 +0000 (10:26 +0200)
committerRenaud Nédélec <renaud.nedelec@opencascade.com>
Wed, 2 Apr 2014 08:26:24 +0000 (10:26 +0200)
src/MEDWrapper/Base/MED_SharedPtr.hxx
src/MEDWrapper/Base/MED_Wrapper.hxx

index 712b4aa46ee48232f4b14456c5debe60dac64b9b..0c52a2062a0843557867e42439426221bb8c95ef 100644 (file)
@@ -48,7 +48,7 @@ namespace MED
     //! Construct the class by any specialisation of the class
     template<class Y>
     SharedPtr(SharedPtr<Y> const & r):
-      boost::shared_ptr<T>(r,boost::detail::dynamic_cast_tag())
+      boost::shared_ptr<T>(boost::dynamic_pointer_cast<T,Y>(r))
     {}
 
     //! Copy-constructor
@@ -56,7 +56,7 @@ namespace MED
     SharedPtr& 
     operator=(SharedPtr<Y> const & r)
     {
-      boost::shared_ptr<T>(r,boost::detail::dynamic_cast_tag()).swap(*this);
+      SharedPtr<T>(r).swap(*this);
       return *this;
     }
 
index cd4e8efc3188a7a0df67e65cac76def6ecc7452b..d64d2b853c430dbdf323f6bc5efa97b4ee41af90 100644 (file)
@@ -1002,14 +1002,14 @@ namespace MED
 
     template<class Y>
     SharedPtr(SharedPtr<Y> const & r):
-      boost::shared_ptr<TWrapper>(r,boost::detail::dynamic_cast_tag())
+      boost::shared_ptr<TWrapper>(boost::dynamic_pointer_cast<TWrapper,Y>(r))
     {}
 
     template<class Y>
     SharedPtr& 
     operator=(SharedPtr<Y> const & r)
     {
-      boost::shared_ptr<TWrapper>(r,boost::detail::dynamic_cast_tag()).swap(*this);
+      SharedPtr<TWrapper>(r).swap(*this);
       return *this;
     }