ros-controls / ros_control

Generic and simple controls framework for ROS
http://wiki.ros.org/ros_control
BSD 3-Clause "New" or "Revised" License
470 stars 307 forks source link

Replace boost with std #423

Closed matthew-reynolds closed 4 years ago

matthew-reynolds commented 4 years ago

Part of #403.

Replaces all usages of boost w/ std equivalents available since C++11 or C++14.

Note 1: boost::T::scoped_lock is just a typedef for boost::unique_lock<T>. I could have used the corresponding std::unique_lock<T>, but for our usage, std::lock_guard<T> is fully equivalent and may have slightly less overhead. std::scoped_lock supersedes std::lock_guard, but is only available in C++17.

Note 2: Although boost::ptr_vector offers a lot of functionality/optimizations that std::vector doesn't, in our case we're just holding pointers until they are destructed, we never do anything with them, so we don't care about these differences.

matthew-reynolds commented 4 years ago

~CI failure looks to be unrelated to these changes. One of the builds passed, one failed during install of realtime_tools~

Edit: Thanks to whoever restarted that failed build :)