Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

nullness.hh

Go to the documentation of this file.
00001 
00020 #ifndef MANGO_PTR_NULLNESS_H
00021 #define MANGO_PTR_NULLNESS_H
00022 
00023 namespace MangoPtr
00024 {
00026 const int NullPtr = 0;
00027 
00032 template <typename T>
00033 inline bool 
00034 isNull(T* p) {return 0==p;}
00035 
00040 template <typename T>
00041 inline bool 
00042 isNotNull(T* p) {return 0!=p;}
00043 
00049 template <typename T>
00050 inline void 
00051 nullify(T*& p) {p=0;}
00052 
00053 } // MangoPtr
00054 
00055 #endif // MANGO_PTR_NULLNESS_H

Generated on Tue Nov 12 20:43:52 2002 for Mango-ptr Library by doxygen1.2.18