Go to the documentation of this file.
39 #ifndef __GyotoSmartPointer_H_
40 #define __GyotoSmartPointer_H_
44 class FactoryMessenger;
45 template <
class T>
class SmartPointer;
134 if (
obj &&
obj->decRefCount() == 0) {
136 std::cerr <<
"DEBUG: SmartPointer<"
137 <<
typeid(
obj).name()
138 <<
">::decRef(): delete " <<
obj <<
"\n";
201 obj =
dynamic_cast<T*
>(
const_cast<U*
>(orig()));
214 Gyoto::throwError(
"Null Gyoto::SmartPointer dereference in operator*");
226 Gyoto::throwError(
"Null Gyoto::SmartPointer dereference in operator*");
238 Gyoto::throwError(
"Null Gyoto::SmartPointer dereference in operator->");
245 Gyoto::throwError(
"Null Gyoto::SmartPointer dereference in operator->");
269 right.
obj->incRefCount ();
291 if (
obj)
obj->incRefCount();
300 operator T*() {
return obj; }
302 operator const T*() {
return obj; }
308 operator bool () {
return obj != NULL; }