diff options
author | Martin Braun <martin.braun@ettus.com> | 2019-09-28 12:54:27 +0200 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2019-11-26 12:21:32 -0800 |
commit | fcc2e9c602a6103dfd0f75e035f614b177c5dc35 (patch) | |
tree | 8c6162ab134a79f343b8404f1d82b6bd9483d116 /host/lib/transport/super_recv_packet_handler.hpp | |
parent | 0c43030e71f4786bf1ba1b7f08abf6b3d019761f (diff) | |
download | uhd-fcc2e9c602a6103dfd0f75e035f614b177c5dc35.tar.gz uhd-fcc2e9c602a6103dfd0f75e035f614b177c5dc35.tar.bz2 uhd-fcc2e9c602a6103dfd0f75e035f614b177c5dc35.zip |
uhd: Replace boost::function with std::function
This is mostly a search-and-replace operation, with few exceptions:
- boost::function has a clear() method. In C++11, this is achieved by
assigning nullptr to the std::function object.
- The empty() method is replaced by std::function's bool() operator
Diffstat (limited to 'host/lib/transport/super_recv_packet_handler.hpp')
-rw-r--r-- | host/lib/transport/super_recv_packet_handler.hpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/host/lib/transport/super_recv_packet_handler.hpp b/host/lib/transport/super_recv_packet_handler.hpp index a09281459..b19b50b38 100644 --- a/host/lib/transport/super_recv_packet_handler.hpp +++ b/host/lib/transport/super_recv_packet_handler.hpp @@ -20,7 +20,7 @@ #include <uhd/utils/tasks.hpp> #include <boost/dynamic_bitset.hpp> #include <boost/format.hpp> -#include <boost/function.hpp> +#include <functional> #include <memory> #include <iostream> #include <vector> @@ -36,7 +36,7 @@ UHD_INLINE uint32_t get_context_code( return word0 & 0xff; } -typedef boost::function<void(void)> handle_overflow_type; +typedef std::function<void(void)> handle_overflow_type; static inline void handle_overflow_nop(void) {} /*********************************************************************** @@ -49,12 +49,12 @@ static inline void handle_overflow_nop(void) {} class recv_packet_handler { public: - typedef boost::function<managed_recv_buffer::sptr(double)> get_buff_type; - typedef boost::function<void(const size_t)> handle_flowctrl_type; + typedef std::function<managed_recv_buffer::sptr(double)> get_buff_type; + typedef std::function<void(const size_t)> handle_flowctrl_type; typedef std::function<void(const uint32_t*)> handle_flowctrl_ack_type; - typedef boost::function<void(const stream_cmd_t&)> issue_stream_cmd_type; + typedef std::function<void(const stream_cmd_t&)> issue_stream_cmd_type; typedef void (*vrt_unpacker_type)(const uint32_t*, vrt::if_packet_info_t&); - // typedef boost::function<void(const uint32_t *, vrt::if_packet_info_t &)> + // typedef std::function<void(const uint32_t *, vrt::if_packet_info_t &)> // vrt_unpacker_type; /*! |