From: Luca Heltai Date: Tue, 20 Dec 2022 16:45:56 +0000 (+0100) Subject: Apply suggestions from code review X-Git-Tag: v9.5.0-rc1~714^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9e45803aefaba1e7a9cfadcd643d1cf9130eb620;p=dealii.git Apply suggestions from code review Co-authored-by: David Wells --- diff --git a/doc/news/changes/minor/20221220StefanoZampini-b b/doc/news/changes/minor/20221220StefanoZampini-b index d49048b788..3d1e8e361e 100644 --- a/doc/news/changes/minor/20221220StefanoZampini-b +++ b/doc/news/changes/minor/20221220StefanoZampini-b @@ -1,3 +1,3 @@ New: PETScWrappers:BlockSparseMatrix now is also a PETSc MATNEST type.
-(StefanZampini, 2022/12/20) +(Stefano Zampini, 2022/12/20) diff --git a/include/deal.II/lac/petsc_block_sparse_matrix.h b/include/deal.II/lac/petsc_block_sparse_matrix.h index 8bb025586d..f62d718b2a 100644 --- a/include/deal.II/lac/petsc_block_sparse_matrix.h +++ b/include/deal.II/lac/petsc_block_sparse_matrix.h @@ -279,7 +279,7 @@ namespace PETScWrappers * particular, it should only be used for read-only operations into the * matrix. */ - operator Mat() const; + operator const Mat &() const; /** * Return a reference to the underlying PETSc type. It can be used to diff --git a/source/lac/petsc_parallel_block_sparse_matrix.cc b/source/lac/petsc_parallel_block_sparse_matrix.cc index d744d72f2b..49911c8dee 100644 --- a/source/lac/petsc_parallel_block_sparse_matrix.cc +++ b/source/lac/petsc_parallel_block_sparse_matrix.cc @@ -35,7 +35,7 @@ namespace PETScWrappers BlockSparseMatrix::~BlockSparseMatrix() { PetscErrorCode ierr = destroy_matrix(petsc_nest_matrix); - AssertThrow(ierr == 0, ExcPETScError(ierr)); + AssertNothrow(ierr == 0, ExcPETScError(ierr)); } # ifndef DOXYGEN