From: young Date: Thu, 3 Oct 2013 13:49:54 +0000 (+0000) Subject: One more error identify - only dat out is masked now... X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=85d8cb550e06299d80fe450d399e120480419d47;p=dealii-svn.git One more error identify - only dat out is masked now... git-svn-id: https://svn.dealii.org/branches/branch_petscscalar_complex@31085 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/source/lac/petsc_vector_base.cc b/deal.II/source/lac/petsc_vector_base.cc index ae6e39c52b..f3365e78a4 100644 --- a/deal.II/source/lac/petsc_vector_base.cc +++ b/deal.II/source/lac/petsc_vector_base.cc @@ -416,7 +416,6 @@ namespace PETScWrappers PetscScalar VectorBase::mean_value () const { -#ifndef PETSC_USE_COMPLEX int ierr; // We can only use our more efficient @@ -426,7 +425,12 @@ namespace PETScWrappers PetscScalar sum; ierr = VecSum(vector, &sum); AssertThrow (ierr == 0, ExcPETScError(ierr)); - return sum/size(); +// @whattodo + // return sum/size(); + + Assert ((false), + ExcMessage ("Your PETSc/SLEPc installation was configured with scalar-type complex " + "but this function is not defined for complex types.")); } // get a representation of the vector and @@ -468,15 +472,10 @@ namespace PETScWrappers return mean; -#else // PETSC_USE_COMPLEX + Assert ((false), ExcMessage ("Your PETSc/SLEPc installation was configured with scalar-type complex " "but this function is not defined for complex types.")); - - // Prevent compiler warning about no return value - PetscScalar dummy; - return dummy; -#endif } diff --git a/deal.II/source/lac/slepc_solver.cc b/deal.II/source/lac/slepc_solver.cc index 4e372994d1..4948083bec 100644 --- a/deal.II/source/lac/slepc_solver.cc +++ b/deal.II/source/lac/slepc_solver.cc @@ -248,6 +248,9 @@ namespace SLEPcWrappers PETScWrappers::VectorBase &real_eigenvectors, PETScWrappers::VectorBase &imag_eigenvectors) { + // This function makes no sense if SLEPc was compiled with + // --scaler-type=complex. + #ifndef PETSC_USE_COMPLEX AssertThrow (solver_data.get() != 0, ExcSLEPcWrappersUsageError()); @@ -263,7 +266,6 @@ namespace SLEPcWrappers #endif } - void SolverBase::reset () { diff --git a/deal.II/source/numerics/point_value_history.cc b/deal.II/source/numerics/point_value_history.cc index 17e4a8c3a2..f4d24f5bc1 100644 --- a/deal.II/source/numerics/point_value_history.cc +++ b/deal.II/source/numerics/point_value_history.cc @@ -603,7 +603,13 @@ void PointValueHistory if (mask->second[comp]) { unsigned int solution_index = point->solution_indices[comp]; - data_store_field->second[data_store_index * n_stored + store_index].push_back (solution (solution_index)); +// @whattodo + // data_store_field->second[data_store_index * n_stored + store_index].push_back (solution (solution_index)); + (void) solution_index; // stop g++ complaining: eventually remove this + (void) n_stored; // stop g++ complaining: eventually remove this + Assert ((false), + ExcMessage ("Your PETSc/SLEPc installation was configured with scalar-type complex " + "but this function is not defined for complex types.")); store_index++; } } @@ -1336,9 +1342,7 @@ void PointValueHistory // explicit instantiations -#ifndef PETSC_USE_COMPLEX - #include "point_value_history.inst" -#endif +#include "point_value_history.inst" DEAL_II_NAMESPACE_CLOSE