39 #ifndef BLOCXX_REFERENCE_HPP_
40 #define BLOCXX_REFERENCE_HPP_
41 #include "blocxx/BLOCXX_config.h"
46 namespace BLOCXX_NAMESPACE
52 #if !defined(__GNUC__) || __GNUC__ > 2 // because of a gcc 2.95 ICE
84 #if !defined(__GNUC__) || __GNUC__ > 2 // causes gcc 2.95 to ICE
86 template <
class U>
friend class Reference;
130 typedef char type_must_be_complete[
sizeof(T)];
161 #ifdef BLOCXX_CHECK_NULL_REFERENCES
162 ReferenceHelpers::checkNull(
this);
163 ReferenceHelpers::checkNull(m_pObj);
172 #ifdef BLOCXX_CHECK_NULL_REFERENCES
173 ReferenceHelpers::checkNull(
this);
174 ReferenceHelpers::checkNull(m_pObj);
189 return (m_pObj == 0);
198 rval.
m_pObj =
dynamic_cast<U*
>(m_pObj);
215 template <
class T,
class U>
221 template <
class T,
class U>
227 #if __GNUC__ == 2 && __GNUC_MINOR__ <= 96
230 inline bool operator!=(
const Reference<T>& a,
const Reference<T>& b)
232 return a.getPtr() != b.getPtr();
235 template <
class T,
class U>
239 return a.
getPtr() < b.getPtr();
244 #endif // BLOCXX_REFERENCE_HPP_
bool operator!=(const Array< T > &x, const Array< T > &y)
Determine two Arrays are not equal.
const UInt32 INFINITE_TIMEOUT BLOCXX_DEPRECATED
Value that means infinite timeout.
void swap(ReferenceBase &arg)
void swap(Array< T > &x, Array< T > &y)
#define BLOCXX_SAFE_BOOL_IMPL(classname, type, variable, test)
bool isNull() const BLOCXX_DEPRECATED
void swap(Reference< T > &arg)
bool operator==(const Array< T > &x, const Array< T > &y)
void useRefCountOf(const Reference< U > &)
Reference< U > cast_to() const
Reference< T > & operator=(const Reference< T > &arg)
void useRefCountOf(const ReferenceBase &arg)