From a68733ae7b2aae5b99f46fcbb7bbf868ec0930fc Mon Sep 17 00:00:00 2001 From: David Wells Date: Wed, 23 Aug 2017 18:39:07 -0400 Subject: [PATCH] Work around a compiler bug in a variadic template. GCC 7.1.1 encounters an internal error when parsing the current version of this; we can get around the problem by naming the initializer list of pointers. --- include/deal.II/hp/fe_collection.h | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/include/deal.II/hp/fe_collection.h b/include/deal.II/hp/fe_collection.h index d913b137fc..044d6cd71f 100644 --- a/include/deal.II/hp/fe_collection.h +++ b/include/deal.II/hp/fe_collection.h @@ -458,12 +458,11 @@ namespace hp "Not all of the input arguments of this function " "are derived from FiniteElement!"); - // loop over all of the given arguments and add the finite - // elements to this collection - for (auto p : - { - &fes... - }) + // 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... }; + for (auto p : fe_pointers) push_back (*p); } -- 2.39.5