Skip to content

Commit

Permalink
Another attempt to fix compile warning
Browse files Browse the repository at this point in the history
  • Loading branch information
kronbichler committed Sep 1, 2023
1 parent a2d38d8 commit 13d40e1
Showing 1 changed file with 17 additions and 3 deletions.
20 changes: 17 additions & 3 deletions source/base/tensor_product_polynomials.cc
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,7 @@ namespace internal
} // namespace internal



template <int dim, typename PolynomialType>
void
TensorProductPolynomials<dim, PolynomialType>::evaluate(
Expand All @@ -510,9 +511,6 @@ TensorProductPolynomials<dim, PolynomialType>::evaluate(
std::vector<Tensor<3, dim>> &third_derivatives,
std::vector<Tensor<4, dim>> &fourth_derivatives) const
{
if constexpr (dim == 0)
return;

Assert(dim <= 3, ExcNotImplemented());
Assert(values.size() == this->n() || values.empty(),
ExcDimensionMismatch2(values.size(), this->n(), 0));
Expand Down Expand Up @@ -598,6 +596,22 @@ TensorProductPolynomials<dim, PolynomialType>::evaluate(



template <>
void
TensorProductPolynomials<0, Polynomials::Polynomial<double>>::evaluate(
const Point<0> &,
std::vector<double> &,
std::vector<Tensor<1, 0>> &,
std::vector<Tensor<2, 0>> &,
std::vector<Tensor<3, 0>> &,
std::vector<Tensor<4, 0>> &) const
{
constexpr int dim = 0;
AssertThrow(dim > 0, ExcNotImplemented());
}



template <int dim, typename PolynomialType>
std::unique_ptr<ScalarPolynomialsBase<dim>>
TensorProductPolynomials<dim, PolynomialType>::clone() const
Expand Down

0 comments on commit 13d40e1

Please sign in to comment.