0
0
mirror of https://github.com/yse/easy_profiler.git synced 2024-12-26 08:01:51 +08:00

Remove pointer to parent

This commit is contained in:
Sergey Yagovtsev 2016-06-19 22:37:17 +03:00
parent 739bfb9a17
commit 5e1f390655

View File

@ -14,10 +14,9 @@ struct BlocksTree
{
profiler::SerilizedBlock* node;
std::vector<BlocksTree > children;
BlocksTree* parent;
BlocksTree(){
node = nullptr;
parent = nullptr;
}
BlocksTree(BlocksTree&& that)
@ -36,7 +35,6 @@ struct BlocksTree
delete node;
}
node = nullptr;
parent = nullptr;
}
bool operator < (const BlocksTree& other) const
@ -51,12 +49,9 @@ private:
void makeMove(BlocksTree&& that)
{
node = that.node;
parent = that.parent;
children = std::move(that.children);
that.node = nullptr;
that.parent = nullptr;
}
};