Skip to content

Commit a193987

Browse files
committed
Fix for build errors in nlohmann/json
1 parent d70ee07 commit a193987

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

contrib/json/json.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13706,7 +13706,7 @@ class iter_impl // NOLINT(cppcoreguidelines-special-member-functions,hicpp-speci
1370613706
information refer to: https://github.com/nlohmann/json/issues/1608
1370713707
*/
1370813708
iter_impl(const iter_impl<const BasicJsonType>& other) noexcept
13709-
: m_object(other.m_object), m_it(other.m_it)
13709+
: m_object(const_cast<pointer>(other.m_object)), m_it(other.m_it)
1371013710
{}
1371113711

1371213712
/*!
@@ -13719,7 +13719,7 @@ class iter_impl // NOLINT(cppcoreguidelines-special-member-functions,hicpp-speci
1371913719
{
1372013720
if (&other != this)
1372113721
{
13722-
m_object = other.m_object;
13722+
m_object = const_cast<pointer>(other.m_object);
1372313723
m_it = other.m_it;
1372413724
}
1372513725
return *this;

0 commit comments

Comments
 (0)