diff --git a/include/date/date.h b/include/date/date.h index a7e0849..92cc773 100644 --- a/include/date/date.h +++ b/include/date/date.h @@ -3836,7 +3836,7 @@ public: CONSTCD11 std::chrono::hours hours() const NOEXCEPT {return h_;} CONSTCD11 std::chrono::minutes minutes() const NOEXCEPT {return m_;} CONSTCD11 std::chrono::seconds seconds() const NOEXCEPT {return s_.seconds();} - CONSTCD11 std::chrono::seconds& + CONSTCD14 std::chrono::seconds& seconds(detail::undocumented) NOEXCEPT {return s_.seconds();} CONSTCD11 precision subseconds() const NOEXCEPT {return s_.subseconds();} diff --git a/include/date/tz.h b/include/date/tz.h index 7294076..a02ce8c 100644 --- a/include/date/tz.h +++ b/include/date/tz.h @@ -1922,6 +1922,20 @@ is_leap_second(date::utc_time const& ut) return {ls, ds}; } +struct get_leap_second_info__t +{ + bool is_leap_second; + std::chrono::seconds elapsed; +}; + +template +get_leap_second_info__t +get_leap_second_info(date::utc_time const& ut) +{ + auto p = is_leap_second(ut); + return {p.first, p.second}; +} + template sys_time::type> utc_clock::to_sys(const utc_time& ut)