From f773cf9fb96e25d064f43cffdc893ac905d91f15 Mon Sep 17 00:00:00 2001 From: Martin Braun Date: Sat, 28 Sep 2019 13:13:41 +0200 Subject: uhd: Replace boost::regex with std::regex boost::regex was a requirement until the minimum version of gcc was increased. Since it is at version 5.3 now, using Boost.Regex is no longer necessary. This change is a pure search-and-replace; Boost and std versions of regex are compatible and use the same syntax. --- host/lib/usrp/gps_ctrl.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'host/lib/usrp/gps_ctrl.cpp') diff --git a/host/lib/usrp/gps_ctrl.cpp b/host/lib/usrp/gps_ctrl.cpp index 717654151..f9e03b16a 100644 --- a/host/lib/usrp/gps_ctrl.cpp +++ b/host/lib/usrp/gps_ctrl.cpp @@ -14,7 +14,7 @@ #include #include #include -#include +#include #include #include #include @@ -137,8 +137,8 @@ private: } const std::list keys{"GPGGA", "GPRMC", "SERVO"}; - static const boost::regex servo_regex("^\\d\\d-\\d\\d-\\d\\d.*$"); - static const boost::regex gp_msg_regex("^\\$GP.*,\\*[0-9A-F]{2}$"); + static const std::regex servo_regex("^\\d\\d-\\d\\d-\\d\\d.*$"); + static const std::regex gp_msg_regex("^\\$GP.*,\\*[0-9A-F]{2}$"); std::map msgs; // Get all GPSDO messages available @@ -162,11 +162,11 @@ private: } // Look for SERVO message - if (boost::regex_search(msg, servo_regex, boost::regex_constants::match_continuous)) + if (std::regex_search(msg, servo_regex, std::regex_constants::match_continuous)) { msgs["SERVO"] = msg; } - else if (boost::regex_match(msg, gp_msg_regex) and is_nmea_checksum_ok(msg)) + else if (std::regex_match(msg, gp_msg_regex) and is_nmea_checksum_ok(msg)) { msgs[msg.substr(1,5)] = msg; } -- cgit v1.2.3