mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: free/nullify of PtrList and UPtrList
- Allows clearing or freeing pointers without touching the underlying list size. Was previously only for PtrDynList, but now available on UPtrList, PtrList as well. - add transfer() method to PtrDynList to avoid potential slicing.
This commit is contained in:
@ -155,7 +155,7 @@ void Foam::sampledSets::gatherAllSets()
|
||||
|
||||
const PtrList<sampledSet>& localSets = *this;
|
||||
|
||||
gatheredSets_.clear();
|
||||
gatheredSets_.free();
|
||||
gatheredSets_.resize(localSets.size());
|
||||
gatheredSorting_.resize_nocopy(localSets.size());
|
||||
globalIndices_.resize_nocopy(localSets.size());
|
||||
|
||||
Reference in New Issue
Block a user