From: Bruno Turcksin Date: Fri, 22 Jan 2021 03:25:19 +0000 (-0500) Subject: Merge pull request #11601 from bangerth/ref-cell-6 X-Git-Tag: v9.3.0-rc1~580 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ee55ce0147f817fde2de115b6ee1b2408959502a;p=dealii.git Merge pull request #11601 from bangerth/ref-cell-6 Let ReferenceCell::get_nodal_type_quadrature() return a 'const' reference --- ee55ce0147f817fde2de115b6ee1b2408959502a diff --cc source/grid/reference_cell.cc index 76202e33de,4643d48c7c..81a1820a09 --- a/source/grid/reference_cell.cc +++ b/source/grid/reference_cell.cc @@@ -241,10 -222,8 +241,10 @@@ namespace ReferenceCel return Quadrature(); // never reached } + + template - Quadrature & + const Quadrature & get_nodal_type_quadrature(const Type &reference_cell) { AssertDimension(dim, reference_cell.get_dimension()); @@@ -256,9 -235,10 +256,10 @@@ return Quadrature(tria.get_vertices()); }; - if (reference_cell == get_hypercube(dim)) + if (reference_cell == Type::get_hypercube()) { - static Quadrature quadrature = create_quadrature(reference_cell); + static const Quadrature quadrature = + create_quadrature(reference_cell); return quadrature; } else if (reference_cell == Type::Tri || reference_cell == Type::Tet)