博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
cast shared_ptr to shared_ptr
阅读量:4041 次
发布时间:2019-05-24

本文共 317 字,大约阅读时间需要 1 分钟。

#include 
#include
int main () { std::shared_ptr
foo; std::shared_ptr
bar; foo = std::make_shared
(10); bar = std::const_pointer_cast
(foo); std::cout << "*bar: " << *bar << '\n'; *foo = 20; std::cout << "*bar: " << *bar << '\n'; return 0;}

转载地址:http://maxdi.baihongyu.com/

你可能感兴趣的文章
Oracle 18c 创建PDB可使用的参数说明
查看>>
ORA-39071: Value for EXCLUDE is badly formed.
查看>>
ORA-65359: unable to create pluggable database with no data
查看>>
ORA-12754: Feature PDB SNAPSHOT CAROUSEL is disabled due to missing capability
查看>>
Oracle数据库——Scheduler Job
查看>>
Oracle执行语句跟踪(1)——使用sql trace实现语句追踪
查看>>
oralce 18c 创建PDB几种方式
查看>>
oracle exp 导出表时会发现少表,空表导不出解决方案
查看>>
ORA-14450:试图访问已经在使用的事务处理临时表
查看>>
ORACLE RMAN 各种场景恢复
查看>>
oracle 自动导出package/package body/procedure 等为sql文件并且自动上传到ftp服务器上
查看>>
linux 下 su - oracle 切换不了
查看>>
初学MonggoDb—Linux平台安装MongoDB
查看>>
使用“rz -be”命令上传文件至服务器;使用“sz 文件名”从服务器下载文件到本地
查看>>
mysql:pt-online-schema-change 在线修改表
查看>>
oracle 调整表空间大小 (resize)
查看>>
Oracle scn健康状态检查脚本—scnhealthcheck.sql
查看>>
Redis+TwemProxy(nutcracker)集群部署测试
查看>>
Docker mysql8.0 oltp 性能测试
查看>>
oracle 只开启一个监听端口,却多个端口都可以连接
查看>>