Commit cf916554 authored by Mark Olesen's avatar Mark Olesen Committed by Andrew Heather
Browse files

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.
parent 3e1ee52c
......@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2017-2018 OpenCFD Ltd.
\\ / A nd | Copyright (C) 2017-2019 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
| Copyright (C) 2011-2016 OpenFOAM Foundation
......@@ -32,7 +32,6 @@ License
#include "SLList.H"
#include "IndirectList.H"
#include "UIndirectList.H"
#include "BiIndirectList.H"
#include "contiguous.H"
#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>
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>
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 IndirectList;
template<class T> class UIndirectList;
template<class T> class BiIndirectList;
template<class T> Istream& operator>>(Istream& is, List<T>& list);
......@@ -173,9 +172,6 @@ public:
//- Construct as copy of UIndirectList<T>
explicit List(const UIndirectList<T>& list);
//- Construct as copy of BiIndirectList<T>
explicit List(const BiIndirectList<T>& list);
//- Construct from an initializer list
List(std::initializer_list<T> list);
......@@ -273,9 +269,6 @@ public:
//- Assignment to UIndirectList operator. Takes linear time
void operator=(const UIndirectList<T>& list);
//- Assignment to BiIndirectList operator. Takes linear time
void operator=(const BiIndirectList<T>& list);
//- Assignment to an initializer list
void operator=(std::initializer_list<T> list);
......
......@@ -430,7 +430,7 @@ void Foam::removePoints::setRefinement
mesh_.points(),
savedPoints_,
savedFaces_[saveI] // saved face
)
)()
);
if (meshPoints != keptPoints)
......
Markdown is supported
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