KJB
|
Reference counting pointer class This file contains the code for the classes and class templates making up the Reference Counting Item of More Effective C++ (source code item 29) by Scott Meyers. This code is optimized as follows: in order to avoid small-memory allocations, all classes that use smart pointers are required to inherit from RCObject, such that the reference counter is included in the objects themselves. More...
Go to the source code of this file.
Classes | |
class | spear::RCObject |
class | spear::RCIPtr< T > |
Namespaces | |
spear | |
Functions | |
template<typename T > | |
bool | spear::operator== (const RCIPtr< T > &pointer, const RCIPtr< T > &other) |
template<typename T > | |
bool | spear::operator!= (const RCIPtr< T > &pointer, const RCIPtr< T > &other) |
template<typename T > | |
bool | spear::operator== (const RCIPtr< T > &pointer, const T *other) |
template<typename T > | |
bool | spear::operator== (const T *other, const RCIPtr< T > &pointer) |
template<typename T > | |
bool | spear::operator!= (const RCIPtr< T > &pointer, const T *other) |
template<typename T > | |
bool | spear::operator!= (const T *other, const RCIPtr< T > &pointer) |
Reference counting pointer class This file contains the code for the classes and class templates making up the Reference Counting Item of More Effective C++ (source code item 29) by Scott Meyers. This code is optimized as follows: in order to avoid small-memory allocations, all classes that use smart pointers are required to inherit from RCObject, such that the reference counter is included in the objects themselves.