C++ Builder 参考手册 ➙ System ➙ TObject ➙ Free
头文件:#include <systobj.h>
命名空间:System
函数原型:
void __fastcall Free(void);
System::TObject::Free 是 System::TObject 的成员函数,Delphi 程序可以通过调用 Free 方法来调用析构函数释放分配的内存,空指针和未初始化的对象调用 Free 不会出错。
C++ 程序需要用 delete 来销毁对象,不要调用 Free 方法。
参考:
- System::TObject::NewInstance
- System::TObject::FreeInstance
- System::TObject::InitInstance
- System::TObject::InstanceSize
- System::TObject
- VCL 类继承关系
C++ Builder 参考手册 ➙ System ➙ TObject ➙ Free