mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Field: Added construction from and assignment to zero
This commit is contained in:
@ -60,7 +60,7 @@ Foam::Field<Type>::Field(const label size, const Type& t)
|
||||
template<class Type>
|
||||
Foam::Field<Type>::Field(const label size, const zero)
|
||||
:
|
||||
List<Type>(size, pTraits<Type>::zero)
|
||||
List<Type>(size, Zero)
|
||||
{}
|
||||
|
||||
|
||||
@ -707,6 +707,13 @@ void Foam::Field<Type>::operator=(const Type& t)
|
||||
}
|
||||
|
||||
|
||||
template<class Type>
|
||||
void Foam::Field<Type>::operator=(const zero)
|
||||
{
|
||||
List<Type>::operator=(Zero);
|
||||
}
|
||||
|
||||
|
||||
template<class Type>
|
||||
template<class Form, class Cmpt, Foam::direction nCmpt>
|
||||
void Foam::Field<Type>::operator=(const VectorSpace<Form,Cmpt,nCmpt>& vs)
|
||||
|
||||
@ -347,6 +347,7 @@ public:
|
||||
void operator=(const SubField<Type>&);
|
||||
void operator=(const tmp<Field<Type>>&);
|
||||
void operator=(const Type&);
|
||||
void operator=(const zero);
|
||||
|
||||
template<class Form, class Cmpt, direction nCmpt>
|
||||
void operator=(const VectorSpace<Form,Cmpt,nCmpt>&);
|
||||
|
||||
Reference in New Issue
Block a user