三张图解释为什么 std::shared_ptr 需要保存 weak_count

更正:图里面的shared_core在实现里面一般叫ref_count_base,是一个多态的东西

幻灯片1

幻灯片2

幻灯片3

posted on 2018-04-05 13:04  PointerSMQ  阅读(663)  评论(0编辑  收藏  举报