From: David Wells Date: Sun, 15 Oct 2023 19:35:28 +0000 (-0400) Subject: Use PetscScalar when compressing vectors. X-Git-Tag: relicensing~393^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F16147%2Fhead;p=dealii.git Use PetscScalar when compressing vectors. --- diff --git a/include/deal.II/lac/petsc_vector_base.h b/include/deal.II/lac/petsc_vector_base.h index d936d92aa5..d60193581c 100644 --- a/include/deal.II/lac/petsc_vector_base.h +++ b/include/deal.II/lac/petsc_vector_base.h @@ -1321,7 +1321,7 @@ namespace PETScWrappers int ierr = VecGetArrayRead(*this, &array); AssertThrow(ierr == 0, ExcPETScError(ierr)); - boost::serialization::array_wrapper wrapper( + boost::serialization::array_wrapper wrapper( array, locally_owned_size()); ar &wrapper; @@ -1360,9 +1360,9 @@ namespace PETScWrappers int ierr = VecGetArray(petsc_vector(), &array); AssertThrow(ierr == 0, ExcPETScError(ierr)); - boost::serialization::array_wrapper velocity_wrapper( + boost::serialization::array_wrapper wrapper( array, locally_owned_size()); - ar &velocity_wrapper; + ar &wrapper; ierr = VecRestoreArray(petsc_vector(), &array); AssertThrow(ierr == 0, ExcPETScError(ierr));