Bugfix: const signature handling for manipulateMatrix in fvPatchField
This commit is contained in:
parent
d442bc4693
commit
b7e1ca950a
3 changed files with 8 additions and 4 deletions
|
@ -242,7 +242,7 @@ void Foam::fvPatchField<Type>::evaluate(const Pstream::commsTypes)
|
|||
|
||||
|
||||
template<class Type>
|
||||
void Foam::fvPatchField<Type>::manipulateMatrix(fvMatrix<Type>& matrix) const
|
||||
void Foam::fvPatchField<Type>::manipulateMatrix(fvMatrix<Type>& matrix)
|
||||
{
|
||||
// do nothing
|
||||
}
|
||||
|
|
|
@ -463,7 +463,7 @@ public:
|
|||
// Matrix manipulation
|
||||
|
||||
//- Manipulate matrix
|
||||
virtual void manipulateMatrix(fvMatrix<Type>& matrix) const;
|
||||
virtual void manipulateMatrix(fvMatrix<Type>& matrix);
|
||||
|
||||
|
||||
// I-O
|
||||
|
|
|
@ -729,8 +729,12 @@ void Foam::fvMatrix<Type>::completeAssembly()
|
|||
|
||||
assemblyCompleted_ = true;
|
||||
|
||||
const typename GeometricField<Type, fvPatchField, volMesh>::
|
||||
GeometricBoundaryField& bFields = psi_.boundaryField();
|
||||
// Cast away const to manipulate matrix
|
||||
GeometricField<Type, fvPatchField, volMesh>& ncPsi =
|
||||
const_cast<GeometricField<Type, fvPatchField, volMesh>& >(psi_);
|
||||
|
||||
typename GeometricField<Type, fvPatchField, volMesh>::
|
||||
GeometricBoundaryField& bFields = ncPsi.boundaryField();
|
||||
|
||||
forAll(bFields, patchI)
|
||||
{
|
||||
|
|
Reference in a new issue