Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
0.9.1
-
C++11 compilers with std::shared_ptr support
Description
Most modern compilers now have full support for std::shared_ptr when enable with c++11 flags. It would be nice to have the option to generate code that uses this instead of boost::shared_ptr. This would enable us to remove another boost dependency, on the road to a dependency-free thrift library
Solution summary (so you don't need to wade through the comments):
A new header, <thrift/stdcxx.h>, creates the namespace apache::thrift::stdcxx and aliases the proper std:: or boost:: constructs depending on the capabilities of the environment and whether any build flags are used to force an override of this behavior. All code throughout the project now uses stdcxx:: for all smart_ptr and functional (bind, function, placeholders, _1, _2, ...) constructs.
Attachments
Issue Links
- is duplicated by
-
THRIFT-2241 Use std::shared_ptr instead of boost::shared_ptr
- Closed
- links to