为什么不能直接调用dealloc而是release
dealloc不等于C中的free,dealloc并不将内存释放,也不会将索引计数(Reference counting)降低。于是直接调用dealloc反而无法释放内存。
在Objective-C中,索引计数是起决定性作用的。
为什么不能直接调用dealloc而是release
dealloc不等于C中的free,dealloc并不将内存释放,也不会将索引计数(Reference counting)降低。于是直接调用dealloc反而无法释放内存。
在Objective-C中,索引计数是起决定性作用的。