Comment detach delete logic
Reviewers: dgleich Reviewed By: dgleich Subscribers: pullbot Differential Revision: https://phabricator.memgraph.io/D1260
This commit is contained in:
parent
b7f77d40ad
commit
75c6a57ec2
@ -378,6 +378,9 @@ void GraphDbAccessor::DetachRemoveVertex(VertexAccessor &vertex_accessor) {
|
||||
// can occur. See discussion in the RemoveVertex method above.
|
||||
}
|
||||
vertex_accessor.SwitchNew();
|
||||
// Note that when we call RemoveEdge we must take care not to delete from the
|
||||
// collection we are iterating over. This invalidates the iterator in a subtle
|
||||
// way that does not fail in tests, but is NOT correct.
|
||||
for (auto edge_accessor : vertex_accessor.in())
|
||||
RemoveEdge(edge_accessor, true, false);
|
||||
vertex_accessor.SwitchNew();
|
||||
|
Loading…
Reference in New Issue
Block a user