智能指针 auto_ptr、 shared_ptr 、weak_ptr的使用方法及注意事项
#include<iostream>#include<memory>using namespace std;///////////////////////////////auto_ptr///////////////////////////////////////////////////////////////boost中 scoped_ptr和auto_ptr一样 禁止用户进行拷贝和赋值头文件#include<boost/scoped_ptr.hpp>cl.
原创
2020-07-29 15:58:16 ·
207 阅读 ·
0 评论