Skip to content

Commit ad12d2d

Browse files
committed
Timestamp: Update workaround to support MinGW alongside MSVC
1 parent 5ff6813 commit ad12d2d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

include/rfl/Timestamp.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ class Timestamp {
7272
const std::tm& tm() const { return tm_; }
7373

7474
private:
75-
#ifdef _MSC_VER
76-
// This workaround is necessary, because MSVC doesn't support strptime.
75+
#if defined(_MSC_VER) || defined(__MINGW32__)
76+
// This workaround is necessary, because strptime is not available on Windows.
7777
char* strptime(const char* _s, const char* _f, std::tm* _tm) {
7878
std::istringstream input(_s);
7979
input.imbue(std::locale(setlocale(LC_ALL, nullptr)));

0 commit comments

Comments
 (0)