Commit eef9853a authored by Henry Weller's avatar Henry Weller
Browse files

valuePointPatchField: Change assignment to use the object's internalField...

valuePointPatchField: Change assignment to use the object's internalField rather than that of the argument

Avoids dependency on the state of the argument pointPatchField the
internalField of which may have been de-allocated
parent 12b30732
......@@ -136,11 +136,8 @@ public:
// Disable assignment operators
virtual void operator=(const Field<Type>&)
{}
virtual void operator=(const Type&)
{}
virtual void operator=(const Field<Type>&){}
virtual void operator=(const Type&){}
};
......
......@@ -201,7 +201,7 @@ void Foam::valuePointPatchField<Type>::operator=
const pointPatchField<Type>& ptf
)
{
Field<Type>::operator=(ptf.patchInternalField());
Field<Type>::operator=(this->patchInternalField());
}
......@@ -242,7 +242,7 @@ void Foam::valuePointPatchField<Type>::operator==
const pointPatchField<Type>& ptf
)
{
Field<Type>::operator=(ptf.patchInternalField());
Field<Type>::operator=(this->patchInternalField());
}
......
......@@ -432,35 +432,11 @@ public:
// Member operators
virtual void operator=
(
const pointPatchField<Type>&
)
{}
virtual void operator+=
(
const pointPatchField<Type>&
)
{}
virtual void operator-=
(
const pointPatchField<Type>&
)
{}
virtual void operator*=
(
const pointPatchField<scalar>&
)
{}
virtual void operator/=
(
const pointPatchField<scalar>&
)
{}
virtual void operator=(const pointPatchField<Type>&){}
virtual void operator+=(const pointPatchField<Type>&){}
virtual void operator-=(const pointPatchField<Type>&){}
virtual void operator*=(const pointPatchField<scalar>&){}
virtual void operator/=(const pointPatchField<scalar>&){}
virtual void operator=(const Field<Type>&){}
virtual void operator+=(const Field<Type>&){}
......@@ -480,12 +456,7 @@ public:
// By generic these do nothing unless the patch actually has boundary
// values
virtual void operator==
(
const pointPatchField<Type>&
)
{}
virtual void operator==(const pointPatchField<Type>&){}
virtual void operator==(const Field<Type>&){}
virtual void operator==(const Type&){}
......@@ -527,7 +498,7 @@ const pointPatchField<Type>& operator+
#endif
#define addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField) \
#define addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField) \
addToRunTimeSelectionTable \
( \
PatchTypeField, \
......
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