From c427a52274eaf5b010369c81892a1e3dba581a22 Mon Sep 17 00:00:00 2001 From: barcode Date: Tue, 28 Jun 2022 13:27:46 +0200 Subject: [PATCH] Fix clang-tidy-15 warning about use after move --- include/nlohmann/json.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/nlohmann/json.hpp b/include/nlohmann/json.hpp index 01b716d06..bc73e1631 100644 --- a/include/nlohmann/json.hpp +++ b/include/nlohmann/json.hpp @@ -1204,7 +1204,7 @@ class basic_json // NOLINT(cppcoreguidelines-special-member-functions,hicpp-spec /// @brief move constructor /// @sa https://json.nlohmann.me/api/basic_json/basic_json/ basic_json(basic_json&& other) noexcept - : json_base_class_t(std::move(other)), + : json_base_class_t(static_cast < json_base_class_t&& > (other)), m_type(std::move(other.m_type)), m_value(std::move(other.m_value)) {