diff --git a/include/toml11/fwd/datetime_fwd.hpp b/include/toml11/fwd/datetime_fwd.hpp index 81bdf17..44616a1 100644 --- a/include/toml11/fwd/datetime_fwd.hpp +++ b/include/toml11/fwd/datetime_fwd.hpp @@ -12,17 +12,6 @@ namespace toml { -// To avoid non-threadsafe std::localtime. In C11 (not C++11!), localtime_s is -// provided in the absolutely same purpose, but C++11 is actually not compatible -// with C11. We need to dispatch the function depending on the OS. -namespace detail -{ -std::tm localtime_s(const std::time_t* src); -std::tm gmtime_s(const std::time_t* src); -} // detail - -// ---------------------------------------------------------------------------- - enum class month_t : std::uint8_t { Jan = 0, diff --git a/tests/test_find.cpp b/tests/test_find.cpp index 385b65b..976eede 100644 --- a/tests/test_find.cpp +++ b/tests/test_find.cpp @@ -17,6 +17,15 @@ #include #endif +namespace toml +{ +namespace detail +{ +std::tm localtime_s(const std::time_t* src); +std::tm gmtime_s(const std::time_t* src); +} // detail +} // toml + TEST_CASE("testing toml::find with toml type") { using value_type = toml::value; diff --git a/tests/test_get.cpp b/tests/test_get.cpp index ed46faf..ba8e15e 100644 --- a/tests/test_get.cpp +++ b/tests/test_get.cpp @@ -17,6 +17,15 @@ #include #endif +namespace toml +{ +namespace detail +{ +std::tm localtime_s(const std::time_t* src); +std::tm gmtime_s(const std::time_t* src); +} // detail +} // toml + TEST_CASE("testing toml::get with toml types") { using value_type = toml::value;