Does C++11 standard provide something like boost::any?

前端 未结 4 1270
囚心锁ツ
囚心锁ツ 2021-01-03 23:39

for example boost::function is moved almost entirely to std::function, the same is with boost::shared_ptr

But I can\'t find

4条回答
  •  萌比男神i
    2021-01-04 00:14

    I think the default position was that a library would NOT be included in the new standard unless it was submitted to be included and then passed the committee.

    I am not sure if boost::any was ever submitted. Probably not. However you can still use boost::any.

    My guess is that with C++11 boost libraries will be rewritten, some will be considered redundant and others will be changed to use move semantics, initializer lists and auto thus being written in C++11 style with C++11 features.

    Most likely new libraries will all be in C++11 but existing boost packages will be kept as available for some time to come as many will not have switched to C++11 compilers yet. I would also guess that only features of C++11 that are implemented by all the main compilers will go into the package at first.

    This is probably more a question for programmers than stackoverflow, and even better for comp.std.c++.moderated and boost mailing lists.

提交回复
热议问题