Skip to content

Instantly share code, notes, and snippets.

@alecmce
Created August 21, 2013 15:56
Show Gist options
  • Save alecmce/6296341 to your computer and use it in GitHub Desktop.
Save alecmce/6296341 to your computer and use it in GitHub Desktop.
partial from Object.h, built by #hxcpp
inline OBJ_ *GetPtr() const { return mPtr; }
inline OBJ_ *operator->()
{
#ifdef HXCPP_CHECK_POINTER
if (!mPtr) NullReference("Object", true);
// The handler might have fixed up the null value
if (!mPtr) NullReference("Object", false);
#endif
return mPtr;
}
@alecmce
Copy link
Author

alecmce commented Aug 21, 2013

Just interested what the HXCPP_CHECK_POINTER is for? Just a debugging flag?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment