mirror of
https://github.com/reactos/CMake.git
synced 2024-11-24 12:09:48 +00:00
cmLinkedTree: Add operator* to the iterator.
This commit is contained in:
parent
58853582be
commit
27ff19a96a
@ -87,6 +87,24 @@ public:
|
|||||||
return this->Tree->GetPointer(this->Position - 1);
|
return this->Tree->GetPointer(this->Position - 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ReferenceType operator*() const
|
||||||
|
{
|
||||||
|
assert(this->Tree);
|
||||||
|
assert(this->Tree->UpPositions.size() == this->Tree->Data.size());
|
||||||
|
assert(this->Position <= this->Tree->Data.size());
|
||||||
|
assert(this->Position > 0);
|
||||||
|
return this->Tree->GetReference(this->Position - 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
ReferenceType operator*()
|
||||||
|
{
|
||||||
|
assert(this->Tree);
|
||||||
|
assert(this->Tree->UpPositions.size() == this->Tree->Data.size());
|
||||||
|
assert(this->Position <= this->Tree->Data.size());
|
||||||
|
assert(this->Position > 0);
|
||||||
|
return this->Tree->GetReference(this->Position - 1);
|
||||||
|
}
|
||||||
|
|
||||||
bool operator==(iterator other) const
|
bool operator==(iterator other) const
|
||||||
{
|
{
|
||||||
assert(this->Tree);
|
assert(this->Tree);
|
||||||
|
Loading…
Reference in New Issue
Block a user