批准c ++ xx后,名称空间tr1会发生什么情况? [英] What will happen to namespace tr1 when c++ xx is approved?

查看:86
本文介绍了批准c ++ xx后,名称空间tr1会发生什么情况?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用VS2008中的tr1命名空间编写一些内容.批准C ++ xx后会发生什么?其他C ++修订版本之前是否发生过这种情况? tr1内容仍然可以使用,还是必须更改所有包含的内容?我意识到我正在做出一个很大的假设,即有一天会批准该条约.我知道你们中最有可能没有人为MS工作或为GCC做出贡献,但是如果您有进行此类变更的经验,我将不胜感激.

I'm writing some stuff using the tr1 namespace in VS2008. What will happen when C++xx becomes ratified? Has this happened before with other C++ revisions? Will the tr1 stuff still work or will I have to change all of my include? I realize that I'm making the very large assumption that this ratification will someday occur. I know that most likely none of you work for MS or contribute to GCC, but if you have experience with these kinds of changes, I would appreciate the advice.

推荐答案

std :: tr1将成为C ++ 1x中std的一部分(std :: tr1 :: shared_ptr变为std :: shared_ptr等).只要编译器声称实现TR1,std :: tr1将继续存在.在某些时候,编译器可能会放弃该声明,并因此删除std :: tr1.这可能永远不会发生.

std::tr1 will become part of std in C++1x (std::tr1::shared_ptr becomes std::shared_ptr, etc). std::tr1 will continue to exist as long as that compiler claims to implement TR1. At some point your compiler may drop that claim, and drop std::tr1 as a result. This probably will never happen.

std :: tr1已被复制"到Visual Studio 2010 Beta中的命名空间std中(通过using指令)

std::tr1 has already been "copied" into namespace std in Visual Studio 2010 Beta (via a using directive)

这篇关于批准c ++ xx后,名称空间tr1会发生什么情况?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆