"are derived from PatternBase");
static_assert(sizeof...(ps) > 0,
"The number of PatternTypes must be greater than zero!");
- auto pattern_pointers = {(static_cast<const PatternBase *>(&ps))...};
+ const auto &pattern_pointers = {(static_cast<const PatternBase *>(&ps))...};
for (const auto p : pattern_pointers)
patterns.push_back(p->clone());
}
// loop over all of the given arguments and add the finite elements to
// this collection. Inlining the definition of fe_pointers causes internal
// compiler errors on GCC 7.1.1 so we define it separately:
- const auto fe_pointers = {&fes...};
+ const auto &fe_pointers =
+ std::initializer_list<const FiniteElement<dim, spacedim> *>{&fes...};
for (const auto p : fe_pointers)
push_back(*p);
}
// loop over all of the given arguments and add the quadrature objects to
// this collection. Inlining the definition of q_pointers causes internal
// compiler errors on GCC 7.1.1 so we define it separately:
- const auto q_pointers = {&quadrature_objects...};
+ const auto &q_pointers =
+ std::initializer_list<const Quadrature<dim> *>{&quadrature_objects...};
for (const auto p : q_pointers)
push_back(*p);
}
Assert(triangulation.n_global_active_cells() == 2, ExcInternalError());
Assert(triangulation.n_active_cells() == 2, ExcInternalError());
- hp::FECollection<dim> fe;
- fe.push_back(FE_Q<dim>(2));
- fe.push_back(FE_Q<dim>(2));
+ hp::FECollection<dim> fe(FE_Q<dim>(2), FE_Q<dim>(2));
hp::DoFHandler<dim> dof_handler(triangulation);
if (dof_handler.begin_active()->is_locally_owned())
solution = interpolated;
Vector<double> cellwise_errors(tria.n_active_cells());
- hp::QCollection<dim> quadrature;
- quadrature.push_back(QIterated<dim>(QTrapez<1>(), 5));
+ hp::QCollection<dim> quadrature(QIterated<dim>(QTrapez<1>(), 5));
const dealii::Function<dim, double> *w = nullptr;
VectorTools::integrate_difference(dofh,