Imported Upstream version 14.45.0
[platform/upstream/libzypp.git] / zypp / base / PtrTypes.h
index d0a6cf4..e6d26d1 100644 (file)
@@ -122,8 +122,8 @@ namespace std
   // as the typedef (else g++ will just print the pointer value).
 
   /** \relates zypp::shared_ptr Stream output. */
-  template<class D>
-  inline std::ostream & operator<<( std::ostream & str, const zypp::shared_ptr<D> & obj )
+  template<class _D>
+  inline std::ostream & operator<<( std::ostream & str, const zypp::shared_ptr<_D> & obj )
   {
     if ( obj )
       return str << *obj;
@@ -139,8 +139,8 @@ namespace std
   }
 
   /** \relates zypp::shared_ptr Stream output. */
-  template<class D>
-  inline std::ostream & dumpOn( std::ostream & str, const zypp::shared_ptr<D> & obj )
+  template<class _D>
+  inline std::ostream & dumpOn( std::ostream & str, const zypp::shared_ptr<_D> & obj )
   {
     if ( obj )
       return dumpOn( str, *obj );
@@ -152,16 +152,16 @@ namespace std
   { return str << obj; }
 
   /** \relates zypp::intrusive_ptr Stream output. */
-  template<class D>
-  inline std::ostream & operator<<( std::ostream & str, const zypp::intrusive_ptr<D> & obj )
+  template<class _D>
+  inline std::ostream & operator<<( std::ostream & str, const zypp::intrusive_ptr<_D> & obj )
   {
     if ( obj )
       return str << *obj;
     return str << std::string("NULL");
   }
   /** \relates zypp::intrusive_ptr Stream output. */
-  template<class D>
-  inline std::ostream & dumpOn( std::ostream & str, const zypp::intrusive_ptr<D> & obj )
+  template<class _D>
+  inline std::ostream & dumpOn( std::ostream & str, const zypp::intrusive_ptr<_D> & obj )
   {
     if ( obj )
       return dumpOn( str, *obj );
@@ -180,60 +180,60 @@ namespace zypp
     //
     ///////////////////////////////////////////////////////////////////
     /**
-     * Don't forgett to provide versions for PtrType and constPtrType,
+     * Don't forgett to provide versions for _Ptr and _constPtr,
      * esp. if creation a of temporary is not acceptable (eg. when
      * checking the ref count value).
     */
     namespace rw_pointer {
 
-      template<class D>
+      template<class _D>
         struct Shared
         {
-          typedef shared_ptr<D>       PtrType;
-          typedef shared_ptr<const D> constPtrType;
+          typedef shared_ptr<_D>       _Ptr;
+          typedef shared_ptr<const _D> _constPtr;
           /** Check whether pointer is not shared. */
-          bool unique( const constPtrType & ptr_r )
+          bool unique( const _constPtr & ptr_r )
           { return !ptr_r || ptr_r.unique(); }
-          bool unique( const PtrType & ptr_r )
+          bool unique( const _Ptr & ptr_r )
           { return !ptr_r || ptr_r.unique(); }
           /** Return number of references. */
-          long use_count( const constPtrType & ptr_r ) const
+          long use_count( const _constPtr & ptr_r ) const
           { return ptr_r.use_count(); }
-          long use_count( const PtrType & ptr_r ) const
+          long use_count( const _Ptr & ptr_r ) const
           { return ptr_r.use_count(); }
         };
 
-      template<class D>
+      template<class _D>
         struct Intrusive
         {
-          typedef intrusive_ptr<D>       PtrType;
-          typedef intrusive_ptr<const D> constPtrType;
+          typedef intrusive_ptr<_D>       _Ptr;
+          typedef intrusive_ptr<const _D> _constPtr;
           /** Check whether pointer is not shared. */
-          bool unique( const constPtrType & ptr_r )
+          bool unique( const _constPtr & ptr_r )
           { return !ptr_r || (ptr_r->refCount() <= 1); }
-          bool unique( const PtrType & ptr_r )
+          bool unique( const _Ptr & ptr_r )
           { return !ptr_r || (ptr_r->refCount() <= 1); }
           /** Return number of references. */
-          long use_count( const constPtrType & ptr_r ) const
+          long use_count( const _constPtr & ptr_r ) const
           { return ptr_r ? ptr_r->refCount() : 0; }
-          long use_count( const PtrType & ptr_r ) const
+          long use_count( const _Ptr & ptr_r ) const
           { return ptr_r ? ptr_r->refCount() : 0; }
         };
 
-       template<class D>
+       template<class _D>
         struct Scoped
         {
-          typedef scoped_ptr<D>       PtrType;
-          typedef scoped_ptr<const D> constPtrType;
+          typedef scoped_ptr<_D>       _Ptr;
+          typedef scoped_ptr<const _D> _constPtr;
           /** Check whether pointer is not shared. */
-          bool unique( const constPtrType & ptr_r )
+          bool unique( const _constPtr & ptr_r )
           { return true; }
-          bool unique( const PtrType & ptr_r )
+          bool unique( const _Ptr & ptr_r )
           { return true; }
           /** Return number of references. */
-          long use_count( const constPtrType & ptr_r ) const
+          long use_count( const _constPtr & ptr_r ) const
           { return ptr_r ? 1 : 0; }
-          long use_count( const PtrType & ptr_r ) const
+          long use_count( const _Ptr & ptr_r ) const
           { return ptr_r ? 1 : 0; }
         };
 
@@ -246,10 +246,10 @@ namespace zypp
     //
     /** Wrapper for \c const correct access via \ref ZYPP_SMART_PTR.
      *
-     * zypp::RW_pointer<tt>\<D,DTraits></tt> stores a \ref ZYPP_SMART_PTR
-     * of type \c DTraits::PtrType, which must be convertible into a <tt>D *</tt>.
-     * Pointer style access (via \c -> and \c *) offers a <tt>const D *</tt> in const
-     * a context, otherwise a <tt>D *</tt>. Thus \em RW_ means \em read/write,
+     * zypp::RW_pointer<tt>\<_D,_Traits></tt> stores a \ref ZYPP_SMART_PTR
+     * of type \c _Traits::_Ptr, which must be convertible into a <tt>_D *</tt>.
+     * Pointer style access (via \c -> and \c *) offers a <tt>const _D *</tt> in const
+     * a context, otherwise a <tt>_D *</tt>. Thus \em RW_ means \em read/write,
      * as you get a different type, dependent on whether you're allowed to
      * read or write.
      *
@@ -258,9 +258,9 @@ namespace zypp
      * nonconst implementation methods.
      *
      * The second template argument defaults to
-     * <tt>DTraits = rw_pointer::Shared<D></tt> thus wraping a
-     * <tt>shared_ptr<D></tt>. To wrap an <tt>intrusive_ptr<D></tt>
-     * use <tt>rw_pointer::Intrusive<D></tt>.
+     * <tt>_Traits = rw_pointer::Shared<_D></tt> thus wraping a
+     * <tt>shared_ptr<_D></tt>. To wrap an <tt>intrusive_ptr<_D></tt>
+     * use <tt>rw_pointer::Intrusive<_D></tt>.
      *
      * \see zypp::RWCOW_pointer for 'copy on write' functionality.
      *
@@ -281,11 +281,11 @@ namespace zypp
      * };
      * \endcode
     */
-    template<class D, class DTraits = rw_pointer::Shared<D> >
+    template<class _D, class _Traits = rw_pointer::Shared<_D> >
       struct RW_pointer
       {
-        typedef typename DTraits::PtrType               PtrType;
-        typedef typename DTraits::constPtrType          constPtrType;
+        typedef typename _Traits::_Ptr               _Ptr;
+        typedef typename _Traits::_constPtr          _constPtr;
 
         RW_pointer()
         {}
@@ -294,12 +294,12 @@ namespace zypp
         {}
 
         explicit
-        RW_pointer( typename PtrType::element_type * dptr )
+        RW_pointer( typename _Ptr::element_type * dptr )
         : _dptr( dptr )
         {}
 
         explicit
-        RW_pointer( PtrType dptr )
+        RW_pointer( _Ptr dptr )
         : _dptr( dptr )
         {}
 
@@ -307,66 +307,66 @@ namespace zypp
        { reset(); return *this; }
 
         void reset()
-        { PtrType().swap( _dptr ); }
+        { _Ptr().swap( _dptr ); }
 
-        void reset( typename PtrType::element_type * dptr )
-        { PtrType( dptr ).swap( _dptr ); }
+        void reset( typename _Ptr::element_type * dptr )
+        { _Ptr( dptr ).swap( _dptr ); }
 
         void swap( RW_pointer & rhs )
         { _dptr.swap( rhs._dptr ); }
 
-        void swap( PtrType & rhs )
+        void swap( _Ptr & rhs )
         { _dptr.swap( rhs ); }
 
         explicit operator bool() const
         { return _dptr.get() != nullptr; }
 
-        const D & operator*() const
+        const _D & operator*() const
         { return *_dptr; };
 
-        const D * operator->() const
+        const _D * operator->() const
         { return _dptr.operator->(); }
 
-        const D * get() const
+        const _D * get() const
         { return _dptr.get(); }
 
-        D & operator*()
+        _D & operator*()
         { return *_dptr; }
 
-        D * operator->()
+        _D * operator->()
         { return _dptr.operator->(); }
 
-        D * get()
+        _D * get()
         { return _dptr.get(); }
 
       public:
         bool unique() const
-       { return DTraits().unique( _dptr ); }
+       { return _Traits().unique( _dptr ); }
 
        long use_count() const
-       { return DTraits().use_count( _dptr ); }
+       { return _Traits().use_count( _dptr ); }
 
-        constPtrType getPtr() const
+        _constPtr getPtr() const
         { return _dptr; }
 
-        PtrType getPtr()
+        _Ptr getPtr()
         { return _dptr; }
 
-        constPtrType cgetPtr()
+        _constPtr cgetPtr()
         { return _dptr; }
 
       private:
-        PtrType _dptr;
+        _Ptr _dptr;
       };
     ///////////////////////////////////////////////////////////////////
 
     /** \relates RW_pointer Stream output.
      *
-     * Print the \c D object the RW_pointer refers, or \c "NULL"
+     * Print the \c _D object the RW_pointer refers, or \c "NULL"
      * if the pointer is \c NULL.
      */
-    template<class D, class DPtr>
-      inline std::ostream & operator<<( std::ostream & str, const RW_pointer<D, DPtr> & obj )
+    template<class _D, class _Ptr>
+      inline std::ostream & operator<<( std::ostream & str, const RW_pointer<_D, _Ptr> & obj )
       {
         if ( obj.get() )
           return str << *obj.get();
@@ -374,62 +374,62 @@ namespace zypp
       }
 
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RW_pointer<D, DPtr> & lhs, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RW_pointer<_D, _Ptr> & lhs, const RW_pointer<_D, _Ptr> & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RW_pointer<D, DPtr> & lhs, const typename DPtr::PtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_Ptr & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const typename DPtr::PtrType & lhs, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const typename _Ptr::_Ptr & lhs, const RW_pointer<_D, _Ptr> & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RW_pointer<D, DPtr> & lhs, const typename DPtr::constPtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_constPtr & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const typename DPtr::constPtrType & lhs, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const typename _Ptr::_constPtr & lhs, const RW_pointer<_D, _Ptr> & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RW_pointer<D, DPtr> & lhs, std::nullptr_t )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RW_pointer<_D, _Ptr> & lhs, std::nullptr_t )
       { return( lhs.get() == nullptr ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( std::nullptr_t, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( std::nullptr_t, const RW_pointer<_D, _Ptr> & rhs )
       { return( nullptr == rhs.get() ); }
 
 
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RW_pointer<D, DPtr> & lhs, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RW_pointer<_D, _Ptr> & lhs, const RW_pointer<_D, _Ptr> & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RW_pointer<D, DPtr> & lhs, const typename DPtr::PtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_Ptr & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const typename DPtr::PtrType & lhs, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const typename _Ptr::_Ptr & lhs, const RW_pointer<_D, _Ptr> & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RW_pointer<D, DPtr> & lhs, const typename DPtr::constPtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_constPtr & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const typename DPtr::constPtrType & lhs, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const typename _Ptr::_constPtr & lhs, const RW_pointer<_D, _Ptr> & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RW_pointer<D, DPtr> & lhs, std::nullptr_t )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RW_pointer<_D, _Ptr> & lhs, std::nullptr_t )
       { return( lhs.get() != nullptr ); }
     /** \relates RW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( std::nullptr_t, const RW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( std::nullptr_t, const RW_pointer<_D, _Ptr> & rhs )
       { return( nullptr != rhs.get() ); }
 
     ///////////////////////////////////////////////////////////////////
@@ -437,10 +437,10 @@ namespace zypp
     /** \relates RWCOW_pointer Clone the underlying object.
      * Calls \a rhs <tt>-\>clone()</tt>. Being defined as a
      * function outside \ref RWCOW_pointer allows to overload
-     * it, in case a specific \a D does not have <tt>clone()</tt>.
+     * it, in case a specific \a _D does not have <tt>clone()</tt>.
      */
-    template<class D>
-      inline D * rwcowClone( const D * rhs )
+    template<class _D>
+      inline _D * rwcowClone( const _D * rhs )
       { return rhs->clone(); }
 
     ///////////////////////////////////////////////////////////////////
@@ -454,11 +454,11 @@ namespace zypp
      *
      * See \ref RW_pointer.
     */
-    template<class D, class DTraits = rw_pointer::Shared<D> >
+    template<class _D, class _Traits = rw_pointer::Shared<_D> >
       struct RWCOW_pointer
       {
-        typedef typename DTraits::PtrType               PtrType;
-        typedef typename DTraits::constPtrType          constPtrType;
+        typedef typename _Traits::_Ptr               _Ptr;
+        typedef typename _Traits::_constPtr          _constPtr;
 
        RWCOW_pointer()
        {}
@@ -467,12 +467,12 @@ namespace zypp
        {}
 
         explicit
-        RWCOW_pointer( typename PtrType::element_type * dptr )
+        RWCOW_pointer( typename _Ptr::element_type * dptr )
         : _dptr( dptr )
         {}
 
         explicit
-        RWCOW_pointer( PtrType dptr )
+        RWCOW_pointer( _Ptr dptr )
         : _dptr( dptr )
         {}
 
@@ -480,52 +480,52 @@ namespace zypp
        { reset(); return *this; }
 
         void reset()
-        { PtrType().swap( _dptr ); }
+        { _Ptr().swap( _dptr ); }
 
-        void reset( typename PtrType::element_type * dptr )
-        { PtrType( dptr ).swap( _dptr ); }
+        void reset( typename _Ptr::element_type * dptr )
+        { _Ptr( dptr ).swap( _dptr ); }
 
         void swap( RWCOW_pointer & rhs )
         { _dptr.swap( rhs._dptr ); }
 
-        void swap( PtrType & rhs )
+        void swap( _Ptr & rhs )
         { _dptr.swap( rhs ); }
 
         explicit operator bool() const
        { return _dptr.get() != nullptr; }
 
-        const D & operator*() const
+        const _D & operator*() const
         { return *_dptr; };
 
-        const D * operator->() const
+        const _D * operator->() const
         { return _dptr.operator->(); }
 
-        const D * get() const
+        const _D * get() const
         { return _dptr.get(); }
 
-        D & operator*()
+        _D & operator*()
         { assertUnshared(); return *_dptr; }
 
-        D * operator->()
+        _D * operator->()
         { assertUnshared(); return _dptr.operator->(); }
 
-        D * get()
+        _D * get()
         { assertUnshared(); return _dptr.get(); }
 
       public:
         bool unique() const
-       { return DTraits().unique( _dptr ); }
+       { return _Traits().unique( _dptr ); }
 
        long use_count() const
-       { return DTraits().use_count( _dptr ); }
+       { return _Traits().use_count( _dptr ); }
 
-        constPtrType getPtr() const
+        _constPtr getPtr() const
         { return _dptr; }
 
-        PtrType getPtr()
+        _Ptr getPtr()
         { assertUnshared(); return _dptr; }
 
-        constPtrType cgetPtr()
+        _constPtr cgetPtr()
         { return _dptr; }
 
       private:
@@ -533,21 +533,21 @@ namespace zypp
         void assertUnshared()
         {
           if ( !unique() )
-            PtrType( rwcowClone( _dptr.get() ) ).swap( _dptr );
+            _Ptr( rwcowClone( _dptr.get() ) ).swap( _dptr );
         }
 
       private:
-        PtrType _dptr;
+        _Ptr _dptr;
       };
     ///////////////////////////////////////////////////////////////////
 
     /** \relates RWCOW_pointer Stream output.
      *
-     * Print the \c D object the RWCOW_pointer refers, or \c "NULL"
+     * Print the \c _D object the RWCOW_pointer refers, or \c "NULL"
      * if the pointer is \c NULL.
      */
-    template<class D, class DPtr>
-      inline std::ostream & operator<<( std::ostream & str, const RWCOW_pointer<D, DPtr> & obj )
+    template<class _D, class _Ptr>
+      inline std::ostream & operator<<( std::ostream & str, const RWCOW_pointer<_D, _Ptr> & obj )
       {
         if ( obj.get() )
           return str << *obj.get();
@@ -555,61 +555,61 @@ namespace zypp
       }
 
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RWCOW_pointer<D, DPtr> & lhs, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RWCOW_pointer<_D, _Ptr> & lhs, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RWCOW_pointer<D, DPtr> & lhs, const typename DPtr::PtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RWCOW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_Ptr & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const typename DPtr::PtrType & lhs, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const typename _Ptr::_Ptr & lhs, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RWCOW_pointer<D, DPtr> & lhs, const typename DPtr::constPtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RWCOW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_constPtr & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const typename DPtr::constPtrType & lhs, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( const typename _Ptr::_constPtr & lhs, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return( lhs.get() == rhs.get() ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( const RWCOW_pointer<D, DPtr> & lhs, std::nullptr_t )
+    template<class _D, class _Ptr>
+      inline bool operator==( const RWCOW_pointer<_D, _Ptr> & lhs, std::nullptr_t )
       { return( lhs.get() == nullptr ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator==( std::nullptr_t, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator==( std::nullptr_t, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return( nullptr == rhs.get() ); }
 
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RWCOW_pointer<D, DPtr> & lhs, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RWCOW_pointer<_D, _Ptr> & lhs, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RWCOW_pointer<D, DPtr> & lhs, const typename DPtr::PtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RWCOW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_Ptr & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const typename DPtr::PtrType & lhs, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const typename _Ptr::_Ptr & lhs, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RWCOW_pointer<D, DPtr> & lhs, const typename DPtr::constPtrType & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RWCOW_pointer<_D, _Ptr> & lhs, const typename _Ptr::_constPtr & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const typename DPtr::constPtrType & lhs, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const typename _Ptr::_constPtr & lhs, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return ! ( lhs == rhs ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( const RWCOW_pointer<D, DPtr> & lhs, std::nullptr_t )
+    template<class _D, class _Ptr>
+      inline bool operator!=( const RWCOW_pointer<_D, _Ptr> & lhs, std::nullptr_t )
       { return( lhs.get() != nullptr ); }
     /** \relates RWCOW_pointer */
-    template<class D, class DPtr>
-      inline bool operator!=( std::nullptr_t, const RWCOW_pointer<D, DPtr> & rhs )
+    template<class _D, class _Ptr>
+      inline bool operator!=( std::nullptr_t, const RWCOW_pointer<_D, _Ptr> & rhs )
       { return( nullptr != rhs.get() ); }
 
     ///////////////////////////////////////////////////////////////////