mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: return UList range slice as a SubList
- previously returned the range slice as a UList,
but this prevents convenient assignment.
Apply similar handling for Field/SubField
Allows the following
labelRange range(...);
fullList.slice(range) = identity(range.size());
and
fullList.slice(range) = UIndirectList<T>(other, addr);
ENH: create SubList from full FixedList (simplifies interface)
- allow default constructed SubList. Use shallowCopy to 'reset' later
This commit is contained in:
@ -49,7 +49,7 @@ void printInfo(const SortableList<T>& list)
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
const labelList orig{7, 9, 1, 2, 4, 7, 4, 0};
|
||||
const labelList orig({7, 9, 1, 2, 4, 7, 4, 0});
|
||||
|
||||
labelList order;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user