会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
seekting
博客园
首页
新随笔
联系
管理
订阅
2021年3月11日
对象回收实验
摘要: 对象被释放时,成员变量(不是new出来的)会被自动释放 #include <iostream> #include <memory> using namespace std; class Cat { public: int age; ~Cat() { cout << "~Cat" << endl; }
阅读全文
posted @ 2021-03-11 11:08 seekting
阅读(59)
评论(0)
推荐(0)
公告