mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: remove unneeded, rarely used construct/assign List from BiIndirectList
- the only code location using BiIndirectList are debug sections within polyTopoChange. No need to construct/assign directly from a BiIndirectList since the '()' method provides a simple alternative.
This commit is contained in:
committed by
Andrew Heather
parent
3e1ee52c31
commit
cf91655422
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2017-2018 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 2017-2019 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
| Copyright (C) 2011-2016 OpenFOAM Foundation
|
| Copyright (C) 2011-2016 OpenFOAM Foundation
|
||||||
@ -32,7 +32,6 @@ License
|
|||||||
#include "SLList.H"
|
#include "SLList.H"
|
||||||
#include "IndirectList.H"
|
#include "IndirectList.H"
|
||||||
#include "UIndirectList.H"
|
#include "UIndirectList.H"
|
||||||
#include "BiIndirectList.H"
|
|
||||||
#include "contiguous.H"
|
#include "contiguous.H"
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
|
||||||
@ -340,16 +339,6 @@ Foam::List<T>::List(const UIndirectList<T>& list)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
template<class T>
|
|
||||||
Foam::List<T>::List(const BiIndirectList<T>& list)
|
|
||||||
:
|
|
||||||
UList<T>(nullptr, list.size())
|
|
||||||
{
|
|
||||||
doAlloc();
|
|
||||||
copyList(list);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
Foam::List<T>::List(std::initializer_list<T> list)
|
Foam::List<T>::List(std::initializer_list<T> list)
|
||||||
:
|
:
|
||||||
@ -540,25 +529,6 @@ void Foam::List<T>::operator=(const UIndirectList<T>& list)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
template<class T>
|
|
||||||
void Foam::List<T>::operator=(const BiIndirectList<T>& list)
|
|
||||||
{
|
|
||||||
const label len = list.size();
|
|
||||||
|
|
||||||
reAlloc(len);
|
|
||||||
|
|
||||||
if (len)
|
|
||||||
{
|
|
||||||
List_ACCESS(T, (*this), vp);
|
|
||||||
|
|
||||||
for (label i=0; i<len; ++i)
|
|
||||||
{
|
|
||||||
vp[i] = list[i];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
void Foam::List<T>::operator=(std::initializer_list<T> list)
|
void Foam::List<T>::operator=(std::initializer_list<T> list)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -67,7 +67,6 @@ template<class T> class PtrList;
|
|||||||
template<class T> class SortableList;
|
template<class T> class SortableList;
|
||||||
template<class T> class IndirectList;
|
template<class T> class IndirectList;
|
||||||
template<class T> class UIndirectList;
|
template<class T> class UIndirectList;
|
||||||
template<class T> class BiIndirectList;
|
|
||||||
|
|
||||||
template<class T> Istream& operator>>(Istream& is, List<T>& list);
|
template<class T> Istream& operator>>(Istream& is, List<T>& list);
|
||||||
|
|
||||||
@ -173,9 +172,6 @@ public:
|
|||||||
//- Construct as copy of UIndirectList<T>
|
//- Construct as copy of UIndirectList<T>
|
||||||
explicit List(const UIndirectList<T>& list);
|
explicit List(const UIndirectList<T>& list);
|
||||||
|
|
||||||
//- Construct as copy of BiIndirectList<T>
|
|
||||||
explicit List(const BiIndirectList<T>& list);
|
|
||||||
|
|
||||||
//- Construct from an initializer list
|
//- Construct from an initializer list
|
||||||
List(std::initializer_list<T> list);
|
List(std::initializer_list<T> list);
|
||||||
|
|
||||||
@ -273,9 +269,6 @@ public:
|
|||||||
//- Assignment to UIndirectList operator. Takes linear time
|
//- Assignment to UIndirectList operator. Takes linear time
|
||||||
void operator=(const UIndirectList<T>& list);
|
void operator=(const UIndirectList<T>& list);
|
||||||
|
|
||||||
//- Assignment to BiIndirectList operator. Takes linear time
|
|
||||||
void operator=(const BiIndirectList<T>& list);
|
|
||||||
|
|
||||||
//- Assignment to an initializer list
|
//- Assignment to an initializer list
|
||||||
void operator=(std::initializer_list<T> list);
|
void operator=(std::initializer_list<T> list);
|
||||||
|
|
||||||
|
|||||||
@ -430,7 +430,7 @@ void Foam::removePoints::setRefinement
|
|||||||
mesh_.points(),
|
mesh_.points(),
|
||||||
savedPoints_,
|
savedPoints_,
|
||||||
savedFaces_[saveI] // saved face
|
savedFaces_[saveI] // saved face
|
||||||
)
|
)()
|
||||||
);
|
);
|
||||||
|
|
||||||
if (meshPoints != keptPoints)
|
if (meshPoints != keptPoints)
|
||||||
|
|||||||
Reference in New Issue
Block a user