Skip to content

Commit

Permalink
RCPP-62 Get to bottom of test failure on gcc8
Browse files Browse the repository at this point in the history
  • Loading branch information
leemaguire committed Mar 25, 2024
1 parent c696d01 commit ae8e8af
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/cpprealm/bson.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ namespace realm {
bsoncxx::bsoncxx(const bsoncxx& v) noexcept
{
#ifdef CPPREALM_HAVE_GENERATED_BRIDGE_TYPES
*reinterpret_cast<bson::Bson*>(&m_bson) = *reinterpret_cast<const bson::Bson*>(&v.m_bson);
new (&m_bson) bson::Bson(*reinterpret_cast<const bson::Bson*>(&v.m_bson));
#else
m_bson = v.m_bson;
#endif
Expand All @@ -38,7 +38,7 @@ namespace realm {
bsoncxx::bsoncxx(bsoncxx&& v) noexcept
{
#ifdef CPPREALM_HAVE_GENERATED_BRIDGE_TYPES
*reinterpret_cast<bson::Bson*>(&m_bson) = std::move(*reinterpret_cast<bson::Bson*>(&v.m_bson));
new (&m_bson) bson::Bson(std::move(*reinterpret_cast<bson::Bson*>(&v.m_bson)));
#else
m_bson = std::move(v.m_bson);
#endif
Expand Down

0 comments on commit ae8e8af

Please sign in to comment.