diff --git a/src/index/DeltaTriples.cpp b/src/index/DeltaTriples.cpp index de0764a0d6..23776adfa9 100644 --- a/src/index/DeltaTriples.cpp +++ b/src/index/DeltaTriples.cpp @@ -200,10 +200,10 @@ void to_json(nlohmann::json& j, const DeltaTriplesCount& count) { } // ____________________________________________________________________________ -DeltaTriplesCount DeltaTriplesCount::operator-( - const DeltaTriplesCount& other) const { - return {triplesInserted_ - other.triplesInserted_, - triplesDeleted_ - other.triplesDeleted_}; +DeltaTriplesCount operator-(const DeltaTriplesCount& lhs, + const DeltaTriplesCount& rhs) { + return {lhs.triplesInserted_ - rhs.triplesInserted_, + lhs.triplesDeleted_ - rhs.triplesDeleted_}; } // ____________________________________________________________________________ diff --git a/src/index/DeltaTriples.h b/src/index/DeltaTriples.h index 91dac7f237..4c63cef01c 100644 --- a/src/index/DeltaTriples.h +++ b/src/index/DeltaTriples.h @@ -47,7 +47,8 @@ struct DeltaTriplesCount { /// library to allow for implicit conversion. friend void to_json(nlohmann::json& j, const DeltaTriplesCount& count); - DeltaTriplesCount operator-(const DeltaTriplesCount& other) const; + friend DeltaTriplesCount operator-(const DeltaTriplesCount& lhs, + const DeltaTriplesCount& rhs); }; // A class for maintaining triples that are inserted or deleted after index