From 2458f686db271b6307cec98fd71573015c0e63ac Mon Sep 17 00:00:00 2001 From: Julian Brost Date: Fri, 25 Apr 2025 16:17:28 +0200 Subject: [PATCH] tests: Remove GCC compatibility from make_tm We're using C++17, GCC only started implementing that in version 5, so there's no need for compatibility code for older versions any more. --- test/utils.cpp | 5 ----- 1 file changed, 5 deletions(-) diff --git a/test/utils.cpp b/test/utils.cpp index 4008db4a1..41b6a1067 100644 --- a/test/utils.cpp +++ b/test/utils.cpp @@ -23,13 +23,8 @@ tm make_tm(std::string s) } std::tm t = {}; -#if defined(__GNUC__) && __GNUC__ < 5 - // GCC did not implement std::get_time() until version 5 - strptime(s.c_str(), "%Y-%m-%d %H:%M:%S", &t); -#else /* defined(__GNUC__) && __GNUC__ < 5 */ std::istringstream stream(s); stream >> std::get_time(&t, "%Y-%m-%d %H:%M:%S"); -#endif /* defined(__GNUC__) && __GNUC__ < 5 */ t.tm_isdst = dst; return t;