| 774 | } |
| 775 | |
| 776 | void CScriptGrid::Release() const |
| 777 | { |
| 778 | // Clearing the GC flag then descrease the counter |
| 779 | gcFlag = false; |
| 780 | if( asAtomicDec(refCount) == 0 ) |
| 781 | { |
| 782 | // When reaching 0 no more references to this instance |
| 783 | // exists and the object should be destroyed |
| 784 | this->~CScriptGrid(); |
| 785 | userFree(const_cast<CScriptGrid*>(this)); |
| 786 | } |
| 787 | } |
| 788 | |
| 789 | // GC behaviour |
| 790 | int CScriptGrid::GetRefCount() |
no test coverage detected