[Bug c++/96282] [8/9/10/11 Regression] internal compiler error: in output_constructor_regular_field
marxin at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jul 29 09:07:57 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96282
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords|needs-bisection, |
|needs-reduction |
CC| |marxin at gcc dot gnu.org
--- Comment #4 from Martin Liška <marxin at gcc dot gnu.org> ---
Reduced test-case:
#include <array>
template <typename T, typename Ix, Ix Size>
class Pen : std::array<T, Size> {
typedef std::array<T, Size> arr;
public:
// Removing either "constexpr" or ": arr()" from the following
// line seems to work around the problem.
constexpr Pen() : arr() { }
};
class Farm {
public:
enum Sheep { BAA, ZZZ };
template<typename T>
using SheepPen = Pen<T, Sheep, ZZZ>;
};
class Fence {
public:
constexpr Fence() { length = 12; }
int length = 0;
};
void
cull() {
static Farm::SheepPen<Fence> s;
}
Will you look at it Richi?
More information about the Gcc-bugs
mailing list