Commit ef3e39dd authored by mattijs's avatar mattijs
Browse files

reserve doubles storage (like DynamicList)

parent a8c400de
......@@ -670,7 +670,16 @@ inline void Foam::PackedList<nBits>::reserve
// need more capacity?
if (len > StorageList::size())
{
StorageList::setSize(len, 0u);
// Like DynamicList with SizeInc=0, SizeMult=2, SizeDiv=1
StorageList::setSize
(
max
(
len,
StorageList::size()*2
),
0u
);
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment