From 3e4a41bd4a45978abeecae2246dd9dfbc42f015d Mon Sep 17 00:00:00 2001 From: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com> Date: Tue, 3 Jan 2023 11:17:02 -0800 Subject: [PATCH] Remove noexcept specification from Azure::DateTime::clock::now() (#4198) * Remove noexcept specification from Azure::DateTime::clock::now() * Undo unnecessary change (my local clang-format is broken) Co-authored-by: Anton Kolesnyk --- sdk/core/azure-core/CHANGELOG.md | 2 ++ sdk/core/azure-core/inc/azure/core/datetime.hpp | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/sdk/core/azure-core/CHANGELOG.md b/sdk/core/azure-core/CHANGELOG.md index 66e7c1ccd..8b8a4478c 100644 --- a/sdk/core/azure-core/CHANGELOG.md +++ b/sdk/core/azure-core/CHANGELOG.md @@ -8,6 +8,8 @@ ### Breaking Changes +- Removed `noexcept` specification from `Azure::DateTime::clock::now()`. + ### Bugs Fixed ### Other Changes diff --git a/sdk/core/azure-core/inc/azure/core/datetime.hpp b/sdk/core/azure-core/inc/azure/core/datetime.hpp index 4ed531473..54f6d1366 100644 --- a/sdk/core/azure-core/inc/azure/core/datetime.hpp +++ b/sdk/core/azure-core/inc/azure/core/datetime.hpp @@ -39,7 +39,7 @@ namespace _detail { // this clock's time_point), and add that duration to steady clock's time_point to get a new // time_point in the steady clock's "coordinate system". static constexpr bool is_steady = std::chrono::system_clock::is_steady; - static time_point now() noexcept; + static time_point now(); }; } // namespace _detail @@ -202,7 +202,7 @@ public: std::string ToString(DateFormat format, TimeFractionFormat fractionFormat) const; }; -inline _detail::Clock::time_point _detail::Clock::now() noexcept +inline _detail::Clock::time_point _detail::Clock::now() { return DateTime(std::chrono::system_clock::now()); }