C
coala
In Smart Pointer class, we have a piece of code:
inline void release(void) const { if (mPtr) mPtr->release(); mPtr = 0;
}
It can set mPtr but it is still const?
Why could this work and why it can be compiled? We have used it for
years.
Thanks.
- C.
inline void release(void) const { if (mPtr) mPtr->release(); mPtr = 0;
}
It can set mPtr but it is still const?
Why could this work and why it can be compiled? We have used it for
years.
Thanks.
- C.