diff --git a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex/indexedVertex.H b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex/indexedVertex.H index 32ed1d2447321ed3f2b590699bbc39623df1146b..3cbc6acbc890c50feaf2bcb68845d380981b0edf 100644 --- a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex/indexedVertex.H +++ b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex/indexedVertex.H @@ -258,7 +258,7 @@ public: //- Fix the vertex so that it can't be moved inline bool& fixed(); - inline indexedVertex& operator=(const indexedVertex& rhs) + inline void operator=(const indexedVertex& rhs) { Vb::operator=(rhs); @@ -268,8 +268,6 @@ public: this->alignment_ = rhs.alignment(); this->targetCellSize_ = rhs.targetCellSize(); this->vertexFixed_ = rhs.fixed(); - - return *this; } inline bool operator==(const indexedVertex& rhs) const diff --git a/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.C b/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.C index 69cdf15e742ade596dccada3e11f33701492e577..791d53cc591ae792abd441989f0225f76b3e73c6 100644 --- a/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.C +++ b/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -286,8 +286,7 @@ Foam::Xfer<Foam::labelList> Foam::PackedBoolList::used() const // * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * * // -Foam::PackedBoolList& -Foam::PackedBoolList::operator=(const Foam::UList<bool>& lst) +void Foam::PackedBoolList::operator=(const Foam::UList<bool>& lst) { this->setSize(lst.size()); @@ -296,8 +295,6 @@ Foam::PackedBoolList::operator=(const Foam::UList<bool>& lst) { set(elemI, lst[elemI]); } - - return *this; } diff --git a/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.H b/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.H index 904d6f16440e64a5985fbd76e549be205a3dd9db..37620f97f8ec0adeefe6348f11c36f98855021c2 100644 --- a/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.H +++ b/src/OpenFOAM/containers/Lists/PackedList/PackedBoolList.H @@ -191,24 +191,24 @@ public: // Member Operators //- Assignment of all entries to the given value. - inline PackedBoolList& operator=(const bool val); + inline void operator=(const bool val); //- Assignment operator. - inline PackedBoolList& operator=(const PackedBoolList&); + inline void operator=(const PackedBoolList&); //- Assignment operator. - inline PackedBoolList& operator=(const PackedList<1>&); + inline void operator=(const PackedList<1>&); //- Assignment operator. - PackedBoolList& operator=(const Foam::UList<bool>&); + void operator=(const Foam::UList<bool>&); //- Assignment operator, // using the labels as indices to indicate which bits are set - inline PackedBoolList& operator=(const labelUList& indices); + inline void operator=(const labelUList& indices); //- Assignment operator, // using the labels as indices to indicate which bits are set - inline PackedBoolList& operator=(const UIndirectList<label>&); + inline void operator=(const UIndirectList<label>&); //- Complement operator inline PackedBoolList operator~() const; diff --git a/src/OpenFOAM/containers/Lists/PackedList/PackedBoolListI.H b/src/OpenFOAM/containers/Lists/PackedList/PackedBoolListI.H index 772ef763d3cd2de254a33f4498adf3743316245f..d5561cfc28288a636493e4a86c9d7972ab97e416 100644 --- a/src/OpenFOAM/containers/Lists/PackedList/PackedBoolListI.H +++ b/src/OpenFOAM/containers/Lists/PackedList/PackedBoolListI.H @@ -126,47 +126,35 @@ inline Foam::Xfer<Foam::PackedBoolList> Foam::PackedBoolList::xfer() // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // -inline Foam::PackedBoolList& -Foam::PackedBoolList::operator=(const bool val) +inline void Foam::PackedBoolList::operator=(const bool val) { PackedList<1>::operator=(val); - return *this; } -inline Foam::PackedBoolList& -Foam::PackedBoolList::operator=(const PackedBoolList& lst) +inline void Foam::PackedBoolList::operator=(const PackedBoolList& lst) { PackedList<1>::operator=(lst); - return *this; } -inline Foam::PackedBoolList& -Foam::PackedBoolList::operator=(const PackedList<1>& lst) +inline void Foam::PackedBoolList::operator=(const PackedList<1>& lst) { PackedList<1>::operator=(lst); - return *this; } -inline Foam::PackedBoolList& -Foam::PackedBoolList::operator=(const labelUList& indices) +inline void Foam::PackedBoolList::operator=(const labelUList& indices) { clear(); set(indices); - - return *this; } -inline Foam::PackedBoolList& -Foam::PackedBoolList::operator=(const UIndirectList<label>& indices) +inline void Foam::PackedBoolList::operator=(const UIndirectList<label>& indices) { clear(); set(indices); - - return *this; } diff --git a/src/OpenFOAM/containers/Lists/PackedList/PackedList.C b/src/OpenFOAM/containers/Lists/PackedList/PackedList.C index c1b54b68b33f7dfce673b1a19b91d240290cf22d..576471c9a9a4d49ad2da9a7572479d74a7273789 100644 --- a/src/OpenFOAM/containers/Lists/PackedList/PackedList.C +++ b/src/OpenFOAM/containers/Lists/PackedList/PackedList.C @@ -513,18 +513,15 @@ void Foam::PackedList<nBits>::writeEntry // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<unsigned nBits> -Foam::PackedList<nBits>& -Foam::PackedList<nBits>::operator=(const PackedList<nBits>& lst) +void Foam::PackedList<nBits>::operator=(const PackedList<nBits>& lst) { StorageList::operator=(lst); size_ = lst.size(); - return *this; } template<unsigned nBits> -Foam::PackedList<nBits>& -Foam::PackedList<nBits>::operator=(const labelUList& lst) +void Foam::PackedList<nBits>::operator=(const labelUList& lst) { setCapacity(lst.size()); size_ = lst.size(); @@ -533,13 +530,11 @@ Foam::PackedList<nBits>::operator=(const labelUList& lst) { set(i, lst[i]); } - return *this; } template<unsigned nBits> -Foam::PackedList<nBits>& -Foam::PackedList<nBits>::operator=(const UIndirectList<label>& lst) +void Foam::PackedList<nBits>::operator=(const UIndirectList<label>& lst) { setCapacity(lst.size()); size_ = lst.size(); @@ -548,7 +543,6 @@ Foam::PackedList<nBits>::operator=(const UIndirectList<label>& lst) { set(i, lst[i]); } - return *this; } diff --git a/src/OpenFOAM/containers/Lists/PackedList/PackedList.H b/src/OpenFOAM/containers/Lists/PackedList/PackedList.H index 8b44cc362bf2a91febca667f20e205ba72776e32..7f038c159bcda9c4e7427466a14234f383cd624c 100644 --- a/src/OpenFOAM/containers/Lists/PackedList/PackedList.H +++ b/src/OpenFOAM/containers/Lists/PackedList/PackedList.H @@ -398,16 +398,16 @@ public: inline iteratorBase operator[](const label); //- Assignment of all entries to the given value. Takes linear time. - inline PackedList<nBits>& operator=(const unsigned int val); + inline void operator=(const unsigned int val); //- Assignment operator. - PackedList<nBits>& operator=(const PackedList<nBits>&); + void operator=(const PackedList<nBits>&); //- Assignment operator. - PackedList<nBits>& operator=(const labelUList&); + void operator=(const labelUList&); //- Assignment operator. - PackedList<nBits>& operator=(const UIndirectList<label>&); + void operator=(const UIndirectList<label>&); // Iterators and helpers @@ -468,11 +468,11 @@ public: //- Assign value, not position. // This allows packed[0] = packed[3] for assigning values - inline unsigned int operator=(const iteratorBase&); + inline void operator=(const iteratorBase&); //- Assign value. // A non-existent entry will be auto-vivified. - inline unsigned int operator=(const unsigned int val); + inline void operator=(const unsigned int val); //- Conversion operator // Never auto-vivify entries. @@ -522,7 +522,7 @@ public: //- Assign from iteratorBase, eg iter = packedlist[i] // An out-of-range iterator is assigned end() - inline iterator& operator=(const iteratorBase&); + inline void operator=(const iteratorBase&); //- Return value inline unsigned int operator*() const; @@ -583,7 +583,7 @@ public: //- Assign from iteratorBase or derived // eg, iter = packedlist[i] or even iter = list.begin() - inline const_iterator& operator=(const iteratorBase&); + inline void operator=(const iteratorBase&); //- Return referenced value directly inline unsigned int operator*() const; diff --git a/src/OpenFOAM/containers/Lists/PackedList/PackedListI.H b/src/OpenFOAM/containers/Lists/PackedList/PackedListI.H index e4a56f9b701213eb9381bc270d5283c067e9fad2..4b6898cf5e61f47b5df603bf2cf80b63889702ae 100644 --- a/src/OpenFOAM/containers/Lists/PackedList/PackedListI.H +++ b/src/OpenFOAM/containers/Lists/PackedList/PackedListI.H @@ -356,18 +356,21 @@ inline bool Foam::PackedList<nBits>::iteratorBase::operator!= template<unsigned nBits> -inline unsigned int -Foam::PackedList<nBits>::iteratorBase::operator=(const iteratorBase& iter) +inline void Foam::PackedList<nBits>::iteratorBase::operator= +( + const iteratorBase& iter +) { const unsigned int val = iter.get(); this->set(val); - return val; } template<unsigned nBits> -inline unsigned int -Foam::PackedList<nBits>::iteratorBase::operator=(const unsigned int val) +inline void Foam::PackedList<nBits>::iteratorBase::operator= +( + const unsigned int val +) { // lazy evaluation - increase size on assigment if (index_ >= list_->size_) @@ -376,7 +379,6 @@ Foam::PackedList<nBits>::iteratorBase::operator=(const unsigned int val) } this->set(val); - return val; } @@ -517,8 +519,10 @@ inline bool Foam::PackedList<nBits>::const_iterator::operator!= template<unsigned nBits> -inline typename Foam::PackedList<nBits>::iterator& -Foam::PackedList<nBits>::iterator::operator=(const iteratorBase& iter) +inline void Foam::PackedList<nBits>::iterator::operator= +( + const iteratorBase& iter +) { this->list_ = iter.list_; this->index_ = iter.index_; @@ -529,14 +533,14 @@ Foam::PackedList<nBits>::iterator::operator=(const iteratorBase& iter) { this->index_ = this->list_->size_; } - - return *this; } template<unsigned nBits> -inline typename Foam::PackedList<nBits>::const_iterator& -Foam::PackedList<nBits>::const_iterator::operator=(const iteratorBase& iter) +inline void Foam::PackedList<nBits>::const_iterator::operator= +( + const iteratorBase& iter +) { this->list_ = iter.list_; this->index_ = iter.index_; @@ -1066,8 +1070,7 @@ Foam::PackedList<nBits>::operator[](const label i) template<unsigned nBits> -inline Foam::PackedList<nBits>& -Foam::PackedList<nBits>::operator=(const unsigned int val) +inline void Foam::PackedList<nBits>::operator=(const unsigned int val) { const label packLen = packedLength(); @@ -1111,8 +1114,6 @@ Foam::PackedList<nBits>::operator=(const unsigned int val) StorageList::operator[](i) = 0u; } } - - return *this; } diff --git a/src/OpenFOAM/containers/Lists/PtrList/PtrList.C b/src/OpenFOAM/containers/Lists/PtrList/PtrList.C index d526142159e2d11f03b2f99f40552c4161f86d59..0101d481e61d53beae6d2a23a63e480b1e796786 100644 --- a/src/OpenFOAM/containers/Lists/PtrList/PtrList.C +++ b/src/OpenFOAM/containers/Lists/PtrList/PtrList.C @@ -258,7 +258,7 @@ void Foam::PtrList<T>::reorder(const labelUList& oldToNew) // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class T> -Foam::PtrList<T>& Foam::PtrList<T>::operator=(const PtrList<T>& a) +void Foam::PtrList<T>::operator=(const PtrList<T>& a) { if (this == &a) { @@ -290,9 +290,6 @@ Foam::PtrList<T>& Foam::PtrList<T>::operator=(const PtrList<T>& a) << " for type " << typeid(T).name() << abort(FatalError); } - - - return *this; } diff --git a/src/OpenFOAM/containers/Lists/PtrList/PtrList.H b/src/OpenFOAM/containers/Lists/PtrList/PtrList.H index 80b751c22055aaf4a3c1f270e59b46c2b148e835..68bf3a7157f058976a74014371845ac3a1b3dedd 100644 --- a/src/OpenFOAM/containers/Lists/PtrList/PtrList.H +++ b/src/OpenFOAM/containers/Lists/PtrList/PtrList.H @@ -252,9 +252,8 @@ public: //- Return element const pointer. inline const T* operator()(const label) const; - //- Assignment. - PtrList<T>& operator=(const PtrList<T>&); + void operator=(const PtrList<T>&); // STL type definitions diff --git a/src/OpenFOAM/primitives/bools/Switch/Switch.H b/src/OpenFOAM/primitives/bools/Switch/Switch.H index 4ee6d051a411ef383eab1cadc6cedac725f60335..3538a73006c09a5dccf070abc90c1c930f04b662 100644 --- a/src/OpenFOAM/primitives/bools/Switch/Switch.H +++ b/src/OpenFOAM/primitives/bools/Switch/Switch.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -188,17 +188,15 @@ public: } //- Assignment from enumerated value - const Switch& operator=(const switchType sw) + void operator=(const switchType sw) { switch_ = sw; - return *this; } //- Assignment from bool - const Switch& operator=(const bool b) + void operator=(const bool b) { switch_ = (b ? Switch::TRUE : Switch::FALSE); - return *this; } diff --git a/src/OpenFOAM/primitives/complex/complex.H b/src/OpenFOAM/primitives/complex/complex.H index 8113103e4eae5c6b1062c616734f99ad0c9f7416..debae297feda9aa071c99f0e504199aab68c6c0f 100644 --- a/src/OpenFOAM/primitives/complex/complex.H +++ b/src/OpenFOAM/primitives/complex/complex.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -126,13 +126,13 @@ public: // Member operators - inline const complex& operator=(const complex&); + inline void operator=(const complex&); inline void operator+=(const complex&); inline void operator-=(const complex&); inline void operator*=(const complex&); inline void operator/=(const complex&); - inline const complex& operator=(const scalar); + inline void operator=(const scalar); inline void operator+=(const scalar); inline void operator-=(const scalar); inline void operator*=(const scalar); diff --git a/src/OpenFOAM/primitives/complex/complexI.H b/src/OpenFOAM/primitives/complex/complexI.H index 6d8a9152f9a4a3484620ef4b7ef38ad3a94a28de..0332b3d0d61f7facc7cad5821558c6727644244c 100644 --- a/src/OpenFOAM/primitives/complex/complexI.H +++ b/src/OpenFOAM/primitives/complex/complexI.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -75,11 +75,10 @@ inline complex complex::conjugate() const // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // -inline const complex& complex::operator=(const complex& c) +inline void complex::operator=(const complex& c) { re = c.re; im = c.im; - return *this; } @@ -109,11 +108,10 @@ inline void complex::operator/=(const complex& c) } -inline const complex& complex::operator=(const scalar s) +inline void complex::operator=(const scalar s) { re = s; im = 0.0; - return *this; } diff --git a/src/OpenFOAM/primitives/nullObject/nullObject.H b/src/OpenFOAM/primitives/nullObject/nullObject.H index d324a92500ef60671e6e2f3cb6b50ff4b256b24b..1ec31d5341ac5f212506e5c43944885090391afb 100644 --- a/src/OpenFOAM/primitives/nullObject/nullObject.H +++ b/src/OpenFOAM/primitives/nullObject/nullObject.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2014-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -51,11 +51,11 @@ class NullObject NullObject() {} - //- Prevent copy-construction + //- Disallow default bitwise copy construct NullObject(const NullObject&); - //- Prevent assignment - NullObject& operator=(const NullObject&); + //- Disallow default bitwise assignment + void operator=(const NullObject&); public: diff --git a/src/OpenFOAM/primitives/strings/fileName/fileName.C b/src/OpenFOAM/primitives/strings/fileName/fileName.C index 637e5e1fe0e207716bbd1b3b4c967e648e679707..becb5db393dafb6ae591721926d6614cc2048fc5 100644 --- a/src/OpenFOAM/primitives/strings/fileName/fileName.C +++ b/src/OpenFOAM/primitives/strings/fileName/fileName.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -26,7 +26,6 @@ License #include "fileName.H" #include "wordList.H" #include "DynamicList.H" -#include "debug.H" #include "OSspecific.H" // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // @@ -35,6 +34,7 @@ const char* const Foam::fileName::typeName = "fileName"; int Foam::fileName::debug(debug::debugSwitch(fileName::typeName, 0)); const Foam::fileName Foam::fileName::null; + // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // Foam::fileName::fileName(const wordList& lst) @@ -74,32 +74,18 @@ Foam::fileName& Foam::fileName::toAbsolute() } -// -// * remove repeated slashes -// /abc////def --> /abc/def -// -// * remove '/./' -// /abc/def/./ghi/. --> /abc/def/./ghi -// abc/def/./ --> abc/def -// -// * remove '/../' -// /abc/def/../ghi/jkl/nmo/.. --> /abc/ghi/jkl -// abc/../def/ghi/../jkl --> abc/../def/jkl -// -// * remove trailing '/' -// bool Foam::fileName::clean() { - // the top slash - we are never allowed to go above it + // The top slash - we are never allowed to go above it string::size_type top = this->find('/'); - // no slashes - nothing to do + // No slashes - nothing to do if (top == string::npos) { return false; } - // start with the '/' found: + // Start with the '/' found: char prev = '/'; string::size_type nChar = top+1; string::size_type maxLen = this->size(); @@ -108,47 +94,46 @@ bool Foam::fileName::clean() ( string::size_type src = nChar; src < maxLen; - /*nil*/ ) { char c = operator[](src++); if (prev == '/') { - // repeated '/' - skip it + // Repeated '/' - skip it if (c == '/') { continue; } - // could be '/./' or '/../' + // Could be '/./' or '/../' if (c == '.') { - // found trailing '/.' - skip it + // Found trailing '/.' - skip it if (src >= maxLen) { continue; } - // peek at the next character + // Peek at the next character char c1 = operator[](src); - // found '/./' - skip it + // Found '/./' - skip it if (c1 == '/') { src++; continue; } - // it is '/..' or '/../' + // It is '/..' or '/../' if (c1 == '.' && (src+1 >= maxLen || operator[](src+1) == '/')) { string::size_type parent; - // backtrack to find the parent directory - // minimum of 3 characters: '/x/../' - // strip it, provided it is above the top point + // Backtrack to find the parent directory + // Minimum of 3 characters: '/x/../' + // Strip it, provided it is above the top point if ( nChar > 2 @@ -156,13 +141,13 @@ bool Foam::fileName::clean() && parent >= top ) { - nChar = parent + 1; // retain '/' from the parent + nChar = parent + 1; // Retain '/' from the parent src += 2; continue; } - // bad resolution, eg 'abc/../../' - // retain the sequence, but move the top to avoid it being + // Bad resolution, eg 'abc/../../' + // Retain the sequence, but move the top to avoid it being // considered a valid parent later top = nChar + 2; } @@ -171,7 +156,7 @@ bool Foam::fileName::clean() operator[](nChar++) = prev = c; } - // remove trailing slash + // Remove trailing slash if (nChar > 1 && operator[](nChar-1) == '/') { nChar--; @@ -191,18 +176,6 @@ Foam::fileName Foam::fileName::clean() const } - -// Return file name (part beyond last /) -// -// behaviour compared to /usr/bin/basename: -// input name() basename -// ----- ------ -------- -// "foo" "foo" "foo" -// "/foo" "foo" "foo" -// "foo/bar" "bar" "bar" -// "/foo/bar" "bar" "bar" -// "/foo/bar/" "" "bar" -// Foam::word Foam::fileName::name() const { size_type i = rfind('/'); @@ -273,17 +246,6 @@ Foam::word Foam::fileName::name(const bool noExt) const } -// Return directory path name (part before last /) -// -// behaviour compared to /usr/bin/dirname: -// input path() dirname -// ----- ------ ------- -// "foo" "." "." -// "/foo" "/" "foo" -// "foo/bar" "foo" "foo" -// "/foo/bar" "/foo" "/foo" -// "/foo/bar/" "/foo/bar/" "/foo" -// Foam::fileName Foam::fileName::path() const { size_type i = rfind('/'); @@ -303,7 +265,6 @@ Foam::fileName Foam::fileName::path() const } -// Return file name without extension (part before last .) Foam::fileName Foam::fileName::lessExt() const { size_type i = find_last_of("./"); @@ -319,7 +280,6 @@ Foam::fileName Foam::fileName::lessExt() const } -// Return file name extension (part after last .) Foam::word Foam::fileName::ext() const { size_type i = find_last_of("./"); @@ -335,19 +295,6 @@ Foam::word Foam::fileName::ext() const } -// Return the components of the file name as a wordList -// note that concatenating the components will not necessarily retrieve -// the original input fileName -// -// behaviour -// input components() -// ----- ------ -// "foo" 1("foo") -// "/foo" 1("foo") -// "foo/bar" 2("foo", "bar") -// "/foo/bar" 2("foo", "bar") -// "/foo/bar/" 2("foo", "bar") -// Foam::wordList Foam::fileName::components(const char delimiter) const { DynamicList<word> wrdList(20); @@ -356,7 +303,7 @@ Foam::wordList Foam::fileName::components(const char delimiter) const while ((end = find(delimiter, beg)) != npos) { - // avoid empty element (caused by doubled slashes) + // Avoid empty element (caused by doubled slashes) if (beg < end) { wrdList.append(substr(beg, end-beg)); @@ -364,18 +311,17 @@ Foam::wordList Foam::fileName::components(const char delimiter) const beg = end + 1; } - // avoid empty trailing element + // Avoid empty trailing element if (beg < size()) { wrdList.append(substr(beg, npos)); } - // transfer to wordList + // Transfer to wordList return wordList(wrdList.xfer()); } -// Return a component of the file name Foam::word Foam::fileName::component ( const size_type cmpt, @@ -388,41 +334,36 @@ Foam::word Foam::fileName::component // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // -const Foam::fileName& Foam::fileName::operator=(const fileName& str) +void Foam::fileName::operator=(const fileName& str) { string::operator=(str); - return *this; } -const Foam::fileName& Foam::fileName::operator=(const word& str) +void Foam::fileName::operator=(const word& str) { string::operator=(str); - return *this; } -const Foam::fileName& Foam::fileName::operator=(const string& str) +void Foam::fileName::operator=(const string& str) { string::operator=(str); stripInvalid(); - return *this; } -const Foam::fileName& Foam::fileName::operator=(const std::string& str) +void Foam::fileName::operator=(const std::string& str) { string::operator=(str); stripInvalid(); - return *this; } -const Foam::fileName& Foam::fileName::operator=(const char* str) +void Foam::fileName::operator=(const char* str) { string::operator=(str); stripInvalid(); - return *this; } diff --git a/src/OpenFOAM/primitives/strings/fileName/fileName.H b/src/OpenFOAM/primitives/strings/fileName/fileName.H index d6e9684a7a77fd16efc12f7ae8bb628a26df6b1e..ee0d751fae6167cdd5552cc83eac45af21107a3a 100644 --- a/src/OpenFOAM/primitives/strings/fileName/fileName.H +++ b/src/OpenFOAM/primitives/strings/fileName/fileName.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -131,7 +131,20 @@ public: inline static bool valid(char); //- Cleanup file name - // eg, remove repeated slashes, etc. + // + // * Removes repeated slashes + // /abc////def --> /abc/def + // + // * Removes '/./' + // /abc/def/./ghi/. --> /abc/def/./ghi + // abc/def/./ --> abc/def + // + // * Removes '/../' + // /abc/def/../ghi/jkl/nmo/.. --> /abc/ghi/jkl + // abc/../def/ghi/../jkl --> abc/../def/jkl + // + // * Removes trailing '/' + // bool clean(); //- Cleanup file name @@ -154,6 +167,16 @@ public: // Decomposition //- Return file name (part beyond last /) + // + // Behaviour compared to /usr/bin/basename: + // Input name() basename + // ----- ------ -------- + // "foo" "foo" "foo" + // "/foo" "foo" "foo" + // "foo/bar" "bar" "bar" + // "/foo/bar" "bar" "bar" + // "/foo/bar/" "" "bar" + // word name() const; //- Return file name (part beyond last /), subsitute for FOAM_CASE @@ -163,6 +186,16 @@ public: word name(const bool noExt) const; //- Return directory path name (part before last /) + // + // Behaviour compared to /usr/bin/dirname: + // input path() dirname + // ----- ------ ------- + // "foo" "." "." + // "/foo" "/" "foo" + // "foo/bar" "foo" "foo" + // "/foo/bar" "/foo" "/foo" + // "/foo/bar/" "/foo/bar/" "/foo" + // fileName path() const; //- Return file name without extension (part before last .) @@ -172,6 +205,15 @@ public: word ext() const; //- Return path components as wordList + // + // Behaviour: + // Input components() + // ----- ------ + // "foo" 1("foo") + // "/foo" 1("foo") + // "foo/bar" 2("foo", "bar") + // "/foo/bar" 2("foo", "bar") + // "/foo/bar/" 2("foo", "bar") wordList components(const char delimiter='/') const; //- Return a single component of the path @@ -182,11 +224,11 @@ public: // Assignment - const fileName& operator=(const fileName&); - const fileName& operator=(const word&); - const fileName& operator=(const string&); - const fileName& operator=(const std::string&); - const fileName& operator=(const char*); + void operator=(const fileName&); + void operator=(const word&); + void operator=(const string&); + void operator=(const std::string&); + void operator=(const char*); // IOstream operators diff --git a/src/OpenFOAM/primitives/strings/keyType/keyType.H b/src/OpenFOAM/primitives/strings/keyType/keyType.H index b424a95958357ba1cb4aa0ad2405cd53d14867dc..53ef756ee41ad8b46b8cd4a1b8dddb12c3b7cfa4 100644 --- a/src/OpenFOAM/primitives/strings/keyType/keyType.H +++ b/src/OpenFOAM/primitives/strings/keyType/keyType.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -116,16 +116,16 @@ public: // Assignment //- Assignment operator - inline const keyType& operator=(const keyType&); + inline void operator=(const keyType&); //- Assign as word, not as non regular expression - inline const keyType& operator=(const word&); + inline void operator=(const word&); //- Assign as regular expression - inline const keyType& operator=(const string&); + inline void operator=(const string&); //- Assign as word, not as non regular expression - inline const keyType& operator=(const char*); + inline void operator=(const char*); // IOstream operators diff --git a/src/OpenFOAM/primitives/strings/keyType/keyTypeI.H b/src/OpenFOAM/primitives/strings/keyType/keyTypeI.H index 136d0cdfeba372a87a5d9ce4c760c629cd0c717a..0f2b8fc3a381cb96ebd6f4e5e6994e50c0fba836 100644 --- a/src/OpenFOAM/primitives/strings/keyType/keyTypeI.H +++ b/src/OpenFOAM/primitives/strings/keyType/keyTypeI.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -81,38 +81,34 @@ inline bool Foam::keyType::isPattern() const // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // -inline const Foam::keyType& Foam::keyType::operator=(const keyType& s) +inline void Foam::keyType::operator=(const keyType& s) { // Bypass checking string::operator=(s); isPattern_ = s.isPattern_; - return *this; } -inline const Foam::keyType& Foam::keyType::operator=(const word& s) +inline void Foam::keyType::operator=(const word& s) { word::operator=(s); isPattern_ = false; - return *this; } -inline const Foam::keyType& Foam::keyType::operator=(const string& s) +inline void Foam::keyType::operator=(const string& s) { // Bypass checking string::operator=(s); isPattern_ = true; - return *this; } -inline const Foam::keyType& Foam::keyType::operator=(const char* s) +inline void Foam::keyType::operator=(const char* s) { // Bypass checking string::operator=(s); isPattern_ = false; - return *this; } diff --git a/src/OpenFOAM/primitives/strings/word/word.H b/src/OpenFOAM/primitives/strings/word/word.H index 65d3b7032be25fdd2421cf26482daf3beaf0cacb..4b51809306b9165cc7263f0ff46c1dac15411f94 100644 --- a/src/OpenFOAM/primitives/strings/word/word.H +++ b/src/OpenFOAM/primitives/strings/word/word.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -117,10 +117,10 @@ public: // Assignment - inline const word& operator=(const word&); - inline const word& operator=(const string&); - inline const word& operator=(const std::string&); - inline const word& operator=(const char*); + inline void operator=(const word&); + inline void operator=(const string&); + inline void operator=(const std::string&); + inline void operator=(const char*); // Friend Operators diff --git a/src/OpenFOAM/primitives/strings/word/wordI.H b/src/OpenFOAM/primitives/strings/word/wordI.H index b1fb7b7c3e8670e08daece46d63c0a6ea06d8058..587adfac99b3d8378e3c1768e1d52f06012d0ae1 100644 --- a/src/OpenFOAM/primitives/strings/word/wordI.H +++ b/src/OpenFOAM/primitives/strings/word/wordI.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -131,34 +131,30 @@ inline bool Foam::word::valid(char c) // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // -inline const Foam::word& Foam::word::operator=(const word& q) +inline void Foam::word::operator=(const word& q) { string::operator=(q); - return *this; } -inline const Foam::word& Foam::word::operator=(const string& q) +inline void Foam::word::operator=(const string& q) { string::operator=(q); stripInvalid(); - return *this; } -inline const Foam::word& Foam::word::operator=(const std::string& q) +inline void Foam::word::operator=(const std::string& q) { string::operator=(q); stripInvalid(); - return *this; } -inline const Foam::word& Foam::word::operator=(const char* q) +inline void Foam::word::operator=(const char* q) { string::operator=(q); stripInvalid(); - return *this; } diff --git a/src/OpenFOAM/primitives/strings/wordRe/wordRe.H b/src/OpenFOAM/primitives/strings/wordRe/wordRe.H index b0cb62e0b43f490c8c62befe5e2d618dfec493ce..47992fe733730e13a48b40817d6c3fc76f3acf05 100644 --- a/src/OpenFOAM/primitives/strings/wordRe/wordRe.H +++ b/src/OpenFOAM/primitives/strings/wordRe/wordRe.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -207,26 +207,26 @@ public: //- Assign copy // Always case sensitive - inline const wordRe& operator=(const wordRe&); + inline void operator=(const wordRe&); //- Copy word, never a regular expression - inline const wordRe& operator=(const word&); + inline void operator=(const word&); //- Copy keyType, auto-test for regular expression // Always case sensitive - inline const wordRe& operator=(const keyType&); + inline void operator=(const keyType&); //- Copy string, auto-test for regular expression // Always case sensitive - inline const wordRe& operator=(const string&); + inline void operator=(const string&); //- Copy string, auto-test for regular expression // Always case sensitive - inline const wordRe& operator=(const std::string&); + inline void operator=(const std::string&); //- Copy string, auto-test for regular expression // Always case sensitive - inline const wordRe& operator=(const char*); + inline void operator=(const char*); // IOstream operators diff --git a/src/OpenFOAM/primitives/strings/wordRe/wordReI.H b/src/OpenFOAM/primitives/strings/wordRe/wordReI.H index 01a3114c6c9b2c6da7c389b501831eaaa7dca735..d35a8134b7c4c06d5648ece5feec6e9ebc9d698a 100644 --- a/src/OpenFOAM/primitives/strings/wordRe/wordReI.H +++ b/src/OpenFOAM/primitives/strings/wordRe/wordReI.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -236,7 +236,7 @@ inline void Foam::wordRe::set(const char* str, const compOption opt) // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // -inline const Foam::wordRe& Foam::wordRe::operator=(const wordRe& str) +inline void Foam::wordRe::operator=(const wordRe& str) { string::operator=(str); @@ -248,50 +248,44 @@ inline const Foam::wordRe& Foam::wordRe::operator=(const wordRe& str) { re_.clear(); } - return *this; } -inline const Foam::wordRe& Foam::wordRe::operator=(const word& str) +inline void Foam::wordRe::operator=(const word& str) { word::operator=(str); re_.clear(); - return *this; } -inline const Foam::wordRe& Foam::wordRe::operator=(const keyType& str) +inline void Foam::wordRe::operator=(const keyType& str) { string::operator=(str); if (str.isPattern()) { compile(); } - return *this; } -inline const Foam::wordRe& Foam::wordRe::operator=(const string& str) +inline void Foam::wordRe::operator=(const string& str) { string::operator=(str); compile(DETECT); // auto-detect regex - return *this; } -inline const Foam::wordRe& Foam::wordRe::operator=(const std::string& str) +inline void Foam::wordRe::operator=(const std::string& str) { string::operator=(str); compile(DETECT); // auto-detect regex - return *this; } -inline const Foam::wordRe& Foam::wordRe::operator=(const char* str) +inline void Foam::wordRe::operator=(const char* str) { string::operator=(str); compile(DETECT); // auto-detect regex - return *this; } diff --git a/src/TurbulenceModels/compressible/RAS/buoyantKEpsilon/buoyantKEpsilon.H b/src/TurbulenceModels/compressible/RAS/buoyantKEpsilon/buoyantKEpsilon.H index 5ac7d56ae26a9608cb7cfb402d9bb6b6e9c5a0c7..f36c0f69a494b61dcc0e1e8c04aadc7c61ad0992 100644 --- a/src/TurbulenceModels/compressible/RAS/buoyantKEpsilon/buoyantKEpsilon.H +++ b/src/TurbulenceModels/compressible/RAS/buoyantKEpsilon/buoyantKEpsilon.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2014-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2014-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -86,7 +86,7 @@ class buoyantKEpsilon // Disallow default bitwise copy construct and assignment buoyantKEpsilon(const buoyantKEpsilon&); - buoyantKEpsilon& operator=(const buoyantKEpsilon&); + void operator=(const buoyantKEpsilon&); protected: diff --git a/src/TurbulenceModels/incompressible/turbulentTransportModels/RAS/LamBremhorstKE/LamBremhorstKE.H b/src/TurbulenceModels/incompressible/turbulentTransportModels/RAS/LamBremhorstKE/LamBremhorstKE.H index 603b5295f1885509673a2c0a7aa8c55c87c4be89..e4719b4f17128cda840f3fa0122d0301e136fa70 100644 --- a/src/TurbulenceModels/incompressible/turbulentTransportModels/RAS/LamBremhorstKE/LamBremhorstKE.H +++ b/src/TurbulenceModels/incompressible/turbulentTransportModels/RAS/LamBremhorstKE/LamBremhorstKE.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -70,7 +70,7 @@ class LamBremhorstKE // Disallow default bitwise copy construct and assignment LamBremhorstKE(const LamBremhorstKE&); - LamBremhorstKE& operator=(const LamBremhorstKE&); + void operator=(const LamBremhorstKE&); tmp<volScalarField> Rt() const; tmp<volScalarField> fMu(const volScalarField& Rt) const; diff --git a/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.H b/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.H index d993c357723c40f3d53f804aa9fb710732279ccc..62b65a9a6c27145075b793bd2ed17a5edcb303d9 100644 --- a/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.H +++ b/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -96,7 +96,7 @@ class NicenoKEqn // Disallow default bitwise copy construct and assignment NicenoKEqn(const NicenoKEqn&); - NicenoKEqn& operator=(const NicenoKEqn&); + void operator=(const NicenoKEqn&); protected: diff --git a/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.H b/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.H index d0d250c4f627d17856288e881bbdc0c09ac6a3b5..4e3e5ef03bacacf002383eed20af8ab36e2be708 100644 --- a/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.H +++ b/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -94,7 +94,7 @@ class SmagorinskyZhang // Disallow default bitwise copy construct and assignment SmagorinskyZhang(const SmagorinskyZhang&); - SmagorinskyZhang& operator=(const SmagorinskyZhang&); + void operator=(const SmagorinskyZhang&); protected: diff --git a/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.H b/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.H index 3893b8cf928d6de639670fda94e5456a026a60e9..fe4b8f20a27383d592f685a10d351d3fc2bff5a5 100644 --- a/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.H +++ b/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -84,7 +84,7 @@ class continuousGasKEqn // Disallow default bitwise copy construct and assignment continuousGasKEqn(const continuousGasKEqn&); - continuousGasKEqn& operator=(const continuousGasKEqn&); + void operator=(const continuousGasKEqn&); protected: diff --git a/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.H b/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.H index 63858ecb46eef5641dabc978f95f9c082af4ce2c..57b2d5da2d810ce2249e45bb107cc7053de4cc95 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.H +++ b/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -98,7 +98,7 @@ class LaheyKEpsilon // Disallow default bitwise copy construct and assignment LaheyKEpsilon(const LaheyKEpsilon&); - LaheyKEpsilon& operator=(const LaheyKEpsilon&); + void operator=(const LaheyKEpsilon&); protected: diff --git a/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.H b/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.H index ab380bc4649b7bea1a5537bdbffaa112ef2a5ffb..60fa636321228ac43c1f10a12b6b3f59c035b376 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.H +++ b/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -91,7 +91,7 @@ class continuousGasKEpsilon // Disallow default bitwise copy construct and assignment continuousGasKEpsilon(const continuousGasKEpsilon&); - continuousGasKEpsilon& operator=(const continuousGasKEpsilon&); + void operator=(const continuousGasKEpsilon&); protected: diff --git a/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.H b/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.H index 6d0f720b7dfadc52f001ac56475d42a1fffabb7d..e25ba65fd7ae6048beb1a9e8dfff6cd9a3c9f4c1 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.H +++ b/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2014-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2014-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -142,7 +142,7 @@ class kOmegaSSTSato // Disallow default bitwise copy construct and assignment kOmegaSSTSato(const kOmegaSSTSato&); - kOmegaSSTSato& operator=(const kOmegaSSTSato&); + void operator=(const kOmegaSSTSato&); protected: diff --git a/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.H b/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.H index 1bf8985e91cf7d92e3bf464144c36af6faa197c0..0f0e835e8ad2364915263e81f1199c507bbc442a 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.H +++ b/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.H @@ -94,7 +94,7 @@ class mixtureKEpsilon // Disallow default bitwise copy construct and assignment mixtureKEpsilon(const mixtureKEpsilon&); - mixtureKEpsilon& operator=(const mixtureKEpsilon&); + void operator=(const mixtureKEpsilon&); //- Return the turbulence model for the other phase mixtureKEpsilon<BasicTurbulenceModel>& liquidTurbulence() const; diff --git a/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.H b/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.H index 241c4598f8cb54a281fafcc944da462fe3862337..f0b57e793738c668d6016a08608795f82944ad78 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.H +++ b/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.H @@ -88,7 +88,7 @@ class DeardorffDiffStress // Disallow default bitwise copy construct and assignment DeardorffDiffStress(const DeardorffDiffStress&); - DeardorffDiffStress& operator=(const DeardorffDiffStress&); + void operator=(const DeardorffDiffStress&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/LESeddyViscosity/LESeddyViscosity.H b/src/TurbulenceModels/turbulenceModels/LES/LESeddyViscosity/LESeddyViscosity.H index f2ac98f60e4a81f17ba39bb4e5aa63f87cb9e3ae..ca9915d137fdb7e58f23fb1f9248f5607a855bfa 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/LESeddyViscosity/LESeddyViscosity.H +++ b/src/TurbulenceModels/turbulenceModels/LES/LESeddyViscosity/LESeddyViscosity.H @@ -61,7 +61,7 @@ class LESeddyViscosity // Disallow default bitwise copy construct and assignment LESeddyViscosity(const LESeddyViscosity&); - LESeddyViscosity& operator=(const LESeddyViscosity&); + void operator=(const LESeddyViscosity&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.H b/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.H index 7b472d39f523d39cd74dca8346ebd5f0a7bb7563..8ed2c4626abb2d1f214c647d5a9e74773824376d 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.H +++ b/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -95,7 +95,7 @@ class Smagorinsky // Disallow default bitwise copy construct and assignment Smagorinsky(const Smagorinsky&); - Smagorinsky& operator=(const Smagorinsky&); + void operator=(const Smagorinsky&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDDES/SpalartAllmarasDDES.H b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDDES/SpalartAllmarasDDES.H index addcb635a4c1dfebf0dd5bf7154b411d517133c0..6e2827650df7e25175d3c7ab5df99dbe39ac8195 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDDES/SpalartAllmarasDDES.H +++ b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDDES/SpalartAllmarasDDES.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -74,7 +74,7 @@ class SpalartAllmarasDDES // Disallow default bitwise copy construct and assignment SpalartAllmarasDDES(const SpalartAllmarasDDES&); - SpalartAllmarasDDES& operator=(const SpalartAllmarasDDES&); + void operator=(const SpalartAllmarasDDES&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.H b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.H index b64ed0d593f1270c314ad1cd38a6e7718cd7b5d4..6fa86abc67d52c5b07daefcb4bcc0ae5e05527b9 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.H +++ b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -69,7 +69,7 @@ class SpalartAllmarasDES // Disallow default bitwise copy construct and assignment SpalartAllmarasDES(const SpalartAllmarasDES&); - SpalartAllmarasDES& operator=(const SpalartAllmarasDES&); + void operator=(const SpalartAllmarasDES&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasIDDES/SpalartAllmarasIDDES.H b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasIDDES/SpalartAllmarasIDDES.H index e2f64aa6bbc13ebfd8a7c24acbe6994495f38921..276af65b20758502fae00a835d5a04037241ac5c 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasIDDES/SpalartAllmarasIDDES.H +++ b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasIDDES/SpalartAllmarasIDDES.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -96,7 +96,7 @@ class SpalartAllmarasIDDES // Disallow default bitwise copy construct and assignment SpalartAllmarasIDDES(const SpalartAllmarasIDDES&); - SpalartAllmarasIDDES& operator=(const SpalartAllmarasIDDES&); + void operator=(const SpalartAllmarasIDDES&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.H b/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.H index 9ac9c00f84e59833c236b20d2f92d003b3db5606..7860f339045111bfab603f4d20e2c1a858afc05d 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.H +++ b/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2015-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -82,7 +82,7 @@ class WALE // Disallow default bitwise copy construct and assignment WALE(const WALE&); - WALE& operator=(const WALE&); + void operator=(const WALE&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.H b/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.H index d9e9ef47cb2563426a0f95186e7a7b61fb038f14..d2f1835c93fe85c1e9cc2538ac05e8c3e4f2248d 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.H +++ b/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -82,7 +82,7 @@ class dynamicKEqn // Disallow default bitwise copy construct and assignment dynamicKEqn(const dynamicKEqn&); - dynamicKEqn& operator=(const dynamicKEqn&); + void operator=(const dynamicKEqn&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.H b/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.H index d95e7730a025f5559788b4f15ba886903027f9a6..74cfa3318878d9b30da7c7761f1597ab7dadf041 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.H +++ b/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -68,7 +68,7 @@ class dynamicLagrangian // Disallow default bitwise copy construct and assignment dynamicLagrangian(const dynamicLagrangian&); - dynamicLagrangian& operator=(const dynamicLagrangian&); + void operator=(const dynamicLagrangian&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.H b/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.H index 6220fc790f6180dbfc5c219fe4ad61cc89e21bf0..19fc999ec308a68e053aee0553247da6a54faf6a 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.H +++ b/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -80,7 +80,7 @@ class kEqn // Disallow default bitwise copy construct and assignment kEqn(const kEqn&); - kEqn& operator=(const kEqn&); + void operator=(const kEqn&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.H b/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.H index 8ebdb31b4664c7c8c184cd1ccfa44d6c4bc49022..bb385757ee25ef444000e40b0bd32c5fe0d0e0e7 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.H @@ -106,7 +106,7 @@ class LRR // Disallow default bitwise copy construct and assignment LRR(const LRR&); - LRR& operator=(const LRR&); + void operator=(const LRR&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.H b/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.H index 09614303d21bbfba1c7324972de9a6307d083fef..5e4f3b0013e476b46a358ac4bac7ce06f17f0100 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.H @@ -90,7 +90,7 @@ class LaunderSharmaKE // Disallow default bitwise copy construct and assignment LaunderSharmaKE(const LaunderSharmaKE&); - LaunderSharmaKE& operator=(const LaunderSharmaKE&); + void operator=(const LaunderSharmaKE&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.H b/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.H index de28164e96eb3d9858290d1b75c177fa0c9258a2..81f39eaf0cf43fa3e4b7975044b4277dc4a47243 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.H @@ -91,7 +91,7 @@ class RNGkEpsilon // Disallow default bitwise copy construct and assignment RNGkEpsilon(const RNGkEpsilon&); - RNGkEpsilon& operator=(const RNGkEpsilon&); + void operator=(const RNGkEpsilon&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.H b/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.H index ac8cfb05f8958283a24c92d9a96a86a5f19e0593..6195edfec40c4b51ba825e25732454849e89b960 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.H @@ -101,7 +101,7 @@ class SSG // Disallow default bitwise copy construct and assignment SSG(const SSG&); - SSG& operator=(const SSG&); + void operator=(const SSG&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.H b/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.H index e4d123e1af3ee0ad4b6107778c78e67177541777..4756e558437f4ef4ee05e681b35af0a04dd2b72b 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.H @@ -94,7 +94,7 @@ class SpalartAllmaras // Disallow default bitwise copy construct and assignment SpalartAllmaras(const SpalartAllmaras&); - SpalartAllmaras& operator=(const SpalartAllmaras&); + void operator=(const SpalartAllmaras&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.H b/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.H index f7690b6aa94615c63c3c4c1c9c1ede4b3f6e1d1f..0877f91fd73aeed676d1f978bffd6de5d02786fc 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.H @@ -92,7 +92,7 @@ class kEpsilon // Disallow default bitwise copy construct and assignment kEpsilon(const kEpsilon&); - kEpsilon& operator=(const kEpsilon&); + void operator=(const kEpsilon&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.H b/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.H index b784dc5b5f75c34e01397ddbee944bb237d72894..56ae2becc418cb96e065c5a05207469280823131 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.H @@ -126,7 +126,7 @@ class kOmegaSST // Disallow default bitwise copy construct and assignment kOmegaSST(const kOmegaSST&); - kOmegaSST& operator=(const kOmegaSST&); + void operator=(const kOmegaSST&); protected: diff --git a/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSSTSAS/kOmegaSSTSAS.H b/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSSTSAS/kOmegaSSTSAS.H index 45588790ed0ad8306c89bb4af0c2c5c78e8a1a76..6a29c5312f230255d6360662b5a1603e0c084c54 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSSTSAS/kOmegaSSTSAS.H +++ b/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSSTSAS/kOmegaSSTSAS.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2015-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -104,7 +104,7 @@ class kOmegaSSTSAS // Disallow default bitwise copy construct and assignment kOmegaSSTSAS(const kOmegaSSTSAS&); - kOmegaSSTSAS& operator=(const kOmegaSSTSAS&); + void operator=(const kOmegaSSTSAS&); protected: diff --git a/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransport.H b/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransport.H index 31af54fe5406b476017f039878e0afd086335ce3..414cb669eea2bdd7248586a7bfd951d1c88b9df3 100644 --- a/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransport.H +++ b/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransport.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -133,10 +133,7 @@ public: // Member operators - inline constAnIsoSolidTransport& operator= - ( - const constAnIsoSolidTransport& - ); + inline void operator=(const constAnIsoSolidTransport&); inline void operator+=(const constAnIsoSolidTransport&); inline void operator-=(const constAnIsoSolidTransport&); diff --git a/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransportI.H b/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransportI.H index 4ec0ae1f7e054130729bbd39e10461d02e791379..fabc997a8ddf58eef0bfe584d1e62d55b0d1751d 100644 --- a/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransportI.H +++ b/src/thermophysicalModels/solidSpecie/transport/const/constAnIsoSolidTransportI.H @@ -98,15 +98,12 @@ alphah(const scalar p, const scalar T) const // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Thermo> -inline Foam::constAnIsoSolidTransport<Thermo>& -Foam::constAnIsoSolidTransport<Thermo>::operator= +inline void Foam::constAnIsoSolidTransport<Thermo>::operator= ( const constAnIsoSolidTransport<Thermo>& ct ) { kappa_ = ct.kappa_; - - return *this; } diff --git a/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransport.H b/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransport.H index d9c47ec44455989d3be7da9e13f2c871f964abdc..2dbe8cded25541e14cfb7b6ad1444bddedbf4674 100644 --- a/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransport.H +++ b/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransport.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -134,10 +134,7 @@ public: // Member operators - inline constIsoSolidTransport& operator= - ( - const constIsoSolidTransport& - ); + inline void operator=(const constIsoSolidTransport&); inline void operator+=(const constIsoSolidTransport&); inline void operator-=(const constIsoSolidTransport&); diff --git a/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransportI.H b/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransportI.H index de1d1cb2775bc365d319d7300e060cac1f4abde9..7ee8ee618e73c89e8525f356f9c683975b68a794 100644 --- a/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransportI.H +++ b/src/thermophysicalModels/solidSpecie/transport/const/constIsoSolidTransportI.H @@ -98,15 +98,13 @@ alphah(const scalar p, const scalar T) const // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class thermo> -inline Foam::constIsoSolidTransport<thermo>& -Foam::constIsoSolidTransport<thermo>::operator= +inline void Foam::constIsoSolidTransport<thermo>::operator= ( const constIsoSolidTransport<thermo>& ct ) { thermo::operator=(ct); kappa_ = ct.kappa_; - return *this; } diff --git a/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransport.H b/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransport.H index 1ea9ffdcac91bb10be54991e00099b741dce293e..32d16b69e0ba0074ab5aa9bafb0326c3c2573901 100644 --- a/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransport.H +++ b/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransport.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -142,10 +142,7 @@ public: // Member operators - inline exponentialSolidTransport& operator= - ( - const exponentialSolidTransport& - ); + inline void operator=(const exponentialSolidTransport&); inline void operator+=(const exponentialSolidTransport&); inline void operator-=(const exponentialSolidTransport&); diff --git a/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransportI.H b/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransportI.H index 8d11b207eb0157e523a16ba9cf80da8d139d0005..909106e5dbb27deba577aaadb52a852acd64d844 100644 --- a/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransportI.H +++ b/src/thermophysicalModels/solidSpecie/transport/exponential/exponentialSolidTransportI.H @@ -111,8 +111,7 @@ alphah(const scalar p, const scalar T) const template<class Thermo> -inline Foam::exponentialSolidTransport<Thermo>& -Foam::exponentialSolidTransport<Thermo>::operator= +inline void Foam::exponentialSolidTransport<Thermo>::operator= ( const exponentialSolidTransport<Thermo>& ct ) @@ -120,7 +119,6 @@ Foam::exponentialSolidTransport<Thermo>::operator= kappa0_ = ct.kappa0_; n0_ = ct.n0_; Tref_ = ct.Tref_; - return *this; } diff --git a/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransport.H b/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransport.H index 90a9e52f6af3b026a42d620e052c5da5dc973abf..5a02e2a7c80a16728a3140688b6dffef7425ffcc 100644 --- a/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransport.H +++ b/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransport.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -172,10 +172,7 @@ public: // Member operators - inline polynomialSolidTransport& operator= - ( - const polynomialSolidTransport& - ); + inline void operator=(const polynomialSolidTransport&); inline void operator+=(const polynomialSolidTransport&); inline void operator-=(const polynomialSolidTransport&); inline void operator*=(const scalar); diff --git a/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransportI.H b/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransportI.H index ad3a0fb2bfc4a2cb5b01f6c1df7c4ffaca67ef68..45d4e95f4952d43c88c73a7e31be94a598dbcf2c 100644 --- a/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransportI.H +++ b/src/thermophysicalModels/solidSpecie/transport/polynomial/polynomialSolidTransportI.H @@ -148,8 +148,7 @@ inline Foam::scalar Foam::polynomialSolidTransport<Thermo, PolySize>::alphah // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Thermo, int PolySize> -inline Foam::polynomialSolidTransport<Thermo, PolySize>& -Foam::polynomialSolidTransport<Thermo, PolySize>::operator= +inline void Foam::polynomialSolidTransport<Thermo, PolySize>::operator= ( const polynomialSolidTransport<Thermo, PolySize>& pt ) @@ -157,8 +156,6 @@ Foam::polynomialSolidTransport<Thermo, PolySize>::operator= Thermo::operator=(pt); kappaCoeffs_ = pt.kappaCoeffs_; - - return *this; } diff --git a/src/thermophysicalModels/specie/equationOfState/Boussinesq/Boussinesq.H b/src/thermophysicalModels/specie/equationOfState/Boussinesq/Boussinesq.H index fd64b7fcdb63a2f0225dce504418b894e423dd80..464f829239a04e67c09a91ccb938219f48316579 100644 --- a/src/thermophysicalModels/specie/equationOfState/Boussinesq/Boussinesq.H +++ b/src/thermophysicalModels/specie/equationOfState/Boussinesq/Boussinesq.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2015-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -194,10 +194,7 @@ public: // Member operators - inline Boussinesq& operator= - ( - const Boussinesq& - ); + inline void operator=(const Boussinesq&); inline void operator+=(const Boussinesq&); inline void operator-=(const Boussinesq&); diff --git a/src/thermophysicalModels/specie/equationOfState/Boussinesq/BoussinesqI.H b/src/thermophysicalModels/specie/equationOfState/Boussinesq/BoussinesqI.H index 573d2225c60b573aec7d9e8685497cc4049aa947..27a729211c09498d7d8dc24bb890bb4f544f41f7 100644 --- a/src/thermophysicalModels/specie/equationOfState/Boussinesq/BoussinesqI.H +++ b/src/thermophysicalModels/specie/equationOfState/Boussinesq/BoussinesqI.H @@ -167,8 +167,7 @@ inline Foam::scalar Foam::Boussinesq<Specie>::cpMcv // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Specie> -inline Foam::Boussinesq<Specie>& -Foam::Boussinesq<Specie>::operator= +inline void Foam::Boussinesq<Specie>::operator= ( const Boussinesq<Specie>& b ) @@ -178,10 +177,9 @@ Foam::Boussinesq<Specie>::operator= rho0_ = b.rho0_; T0_ = b.T0_; beta_ = b.beta_; - - return *this; } + template<class Specie> inline void Foam::Boussinesq<Specie>::operator+= ( diff --git a/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomial.H b/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomial.H index 65ac610a17853b4c8223abed71055db0e7506062..44eb86ffbde6a9813ee2432480ee0d042ffda2a7 100644 --- a/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomial.H +++ b/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomial.H @@ -176,7 +176,7 @@ public: // Member operators - inline icoPolynomial& operator=(const icoPolynomial&); + inline void operator=(const icoPolynomial&); inline void operator+=(const icoPolynomial&); inline void operator-=(const icoPolynomial&); diff --git a/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomialI.H b/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomialI.H index d419397d2a4a95c2e92dae261e3bfdab784bf7cd..c5302e182855285eaef374a216d4a15491f450cb 100644 --- a/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomialI.H +++ b/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomialI.H @@ -157,8 +157,7 @@ inline Foam::scalar Foam::icoPolynomial<Specie, PolySize>::cpMcv // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Specie, int PolySize> -inline Foam::icoPolynomial<Specie, PolySize>& -Foam::icoPolynomial<Specie, PolySize>::operator= +inline void Foam::icoPolynomial<Specie, PolySize>::operator= ( const icoPolynomial<Specie, PolySize>& ip ) @@ -166,8 +165,6 @@ Foam::icoPolynomial<Specie, PolySize>::operator= Specie::operator=(ip); rhoCoeffs_ = ip.rhoCoeffs_; - - return *this; } diff --git a/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGas.H b/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGas.H index 0beacf03e53d3c93e060e891f651af0679e01eb4..922466d7406e43292581725d77abb2c6846217cb 100644 --- a/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGas.H +++ b/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGas.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2012-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2012-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -179,10 +179,7 @@ public: // Member operators - inline incompressiblePerfectGas& operator= - ( - const incompressiblePerfectGas& - ); + inline void operator=(const incompressiblePerfectGas&); inline void operator+=(const incompressiblePerfectGas&); inline void operator-=(const incompressiblePerfectGas&); diff --git a/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGasI.H b/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGasI.H index 9ef59fd40b3b0b9afe6508bb1227e040e4fc1b34..3281e2e613773831a7ac752be1f03a9ffade2f04 100644 --- a/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGasI.H +++ b/src/thermophysicalModels/specie/equationOfState/incompressiblePerfectGas/incompressiblePerfectGasI.H @@ -161,19 +161,16 @@ inline Foam::scalar Foam::incompressiblePerfectGas<Specie>::cpMcv // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Specie> -inline Foam::incompressiblePerfectGas<Specie>& -Foam::incompressiblePerfectGas<Specie>::operator= +inline void Foam::incompressiblePerfectGas<Specie>::operator= ( const incompressiblePerfectGas<Specie>& ipg ) { Specie::operator=(ipg); - pRef_ = ipg.pRef_; - - return *this; } + template<class Specie> inline void Foam::incompressiblePerfectGas<Specie>::operator+= ( diff --git a/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermo.H b/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermo.H index a0b557f215a9b35bff15b48a7a1ad3f902e312d3..ed491b3a00d730264b37817359676482c071f86a 100644 --- a/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermo.H +++ b/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermo.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -187,7 +187,7 @@ public: // Member operators - inline hPolynomialThermo& operator=(const hPolynomialThermo&); + inline void operator=(const hPolynomialThermo&); inline void operator+=(const hPolynomialThermo&); inline void operator-=(const hPolynomialThermo&); inline void operator*=(const scalar); diff --git a/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermoI.H b/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermoI.H index 47b02e3cc70db6b70abdefad7506a70997bbd451..4e8c91f68873263121d2268f00f3e1b1ab8cb5e5 100644 --- a/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermoI.H +++ b/src/thermophysicalModels/specie/thermo/hPolynomial/hPolynomialThermoI.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -144,8 +144,7 @@ inline Foam::scalar Foam::hPolynomialThermo<EquationOfState, PolySize>::s // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class EquationOfState, int PolySize> -inline Foam::hPolynomialThermo<EquationOfState, PolySize>& -Foam::hPolynomialThermo<EquationOfState, PolySize>::operator= +inline void Foam::hPolynomialThermo<EquationOfState, PolySize>::operator= ( const hPolynomialThermo<EquationOfState, PolySize>& pt ) @@ -157,8 +156,6 @@ Foam::hPolynomialThermo<EquationOfState, PolySize>::operator= CpCoeffs_ = pt.CpCoeffs_; hCoeffs_ = pt.hCoeffs_; sCoeffs_ = pt.sCoeffs_; - - return *this; } diff --git a/src/thermophysicalModels/specie/transport/const/constTransport.H b/src/thermophysicalModels/specie/transport/const/constTransport.H index 65cd3c8a418b2c2793a7ec5eb5be23d939319b91..a8c445ff8a18bd9cf317806f04b1e5d4c6ebebd5 100644 --- a/src/thermophysicalModels/specie/transport/const/constTransport.H +++ b/src/thermophysicalModels/specie/transport/const/constTransport.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -161,7 +161,7 @@ public: // Member operators - inline constTransport& operator=(const constTransport&); + inline void operator=(const constTransport&); inline void operator+=(const constTransport&); diff --git a/src/thermophysicalModels/specie/transport/const/constTransportI.H b/src/thermophysicalModels/specie/transport/const/constTransportI.H index 6c597b87d5f62486b563a01e34485fd28b298f60..6c304476fd24366e5505fc4cc694d52ea14c57b9 100644 --- a/src/thermophysicalModels/specie/transport/const/constTransportI.H +++ b/src/thermophysicalModels/specie/transport/const/constTransportI.H @@ -129,7 +129,7 @@ inline Foam::scalar Foam::constTransport<Thermo>::alphah // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Thermo> -inline Foam::constTransport<Thermo>& Foam::constTransport<Thermo>::operator= +inline void Foam::constTransport<Thermo>::operator= ( const constTransport<Thermo>& ct ) @@ -138,8 +138,6 @@ inline Foam::constTransport<Thermo>& Foam::constTransport<Thermo>::operator= mu_ = ct.mu_; rPr_ = ct.rPr_; - - return *this; } diff --git a/src/thermophysicalModels/specie/transport/polynomial/polynomialTransport.H b/src/thermophysicalModels/specie/transport/polynomial/polynomialTransport.H index 85ec167256d409b75362344730b16dd6026dcdf3..768c4fe03437b9ad8e3d34d8d67de203d2de132a 100644 --- a/src/thermophysicalModels/specie/transport/polynomial/polynomialTransport.H +++ b/src/thermophysicalModels/specie/transport/polynomial/polynomialTransport.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -166,7 +166,7 @@ public: // Member operators - inline polynomialTransport& operator=(const polynomialTransport&); + inline void operator=(const polynomialTransport&); inline void operator+=(const polynomialTransport&); inline void operator-=(const polynomialTransport&); inline void operator*=(const scalar); diff --git a/src/thermophysicalModels/specie/transport/polynomial/polynomialTransportI.H b/src/thermophysicalModels/specie/transport/polynomial/polynomialTransportI.H index f51065dfaec52e117d2c4d2e2e742580aba7b409..ca82f18d862ab355a725b2f36ecbe866d6fe23af 100644 --- a/src/thermophysicalModels/specie/transport/polynomial/polynomialTransportI.H +++ b/src/thermophysicalModels/specie/transport/polynomial/polynomialTransportI.H @@ -136,8 +136,7 @@ inline Foam::scalar Foam::polynomialTransport<Thermo, PolySize>::alphah // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Thermo, int PolySize> -inline Foam::polynomialTransport<Thermo, PolySize>& -Foam::polynomialTransport<Thermo, PolySize>::operator= +inline void Foam::polynomialTransport<Thermo, PolySize>::operator= ( const polynomialTransport<Thermo, PolySize>& pt ) @@ -146,8 +145,6 @@ Foam::polynomialTransport<Thermo, PolySize>::operator= muCoeffs_ = pt.muCoeffs_; kappaCoeffs_ = pt.kappaCoeffs_; - - return *this; } diff --git a/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransport.H b/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransport.H index e7da7b9a5ff510522b33758838df9d84616034d0..1033a73de3ad2e6193d4799737e17cec2d77812c 100644 --- a/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransport.H +++ b/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransport.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -186,7 +186,7 @@ public: // Member operators - inline sutherlandTransport& operator=(const sutherlandTransport&); + inline void operator=(const sutherlandTransport&); inline void operator+=(const sutherlandTransport&); diff --git a/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransportI.H b/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransportI.H index 13ba0df2c5f58773dcb48da31e76b7fc270e2454..60ce87da8c532aa200e595bd01125526f2303261 100644 --- a/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransportI.H +++ b/src/thermophysicalModels/specie/transport/sutherland/sutherlandTransportI.H @@ -165,8 +165,7 @@ inline Foam::scalar Foam::sutherlandTransport<Thermo>::alphah // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template<class Thermo> -inline Foam::sutherlandTransport<Thermo>& -Foam::sutherlandTransport<Thermo>::operator= +inline void Foam::sutherlandTransport<Thermo>::operator= ( const sutherlandTransport<Thermo>& st ) @@ -175,8 +174,6 @@ Foam::sutherlandTransport<Thermo>::operator= As_ = st.As_; Ts_ = st.Ts_; - - return *this; }