From 4c1bfef7c57993105fcad395f02e4b77cdad1b21 Mon Sep 17 00:00:00 2001 From: Kai Tietz Date: Thu, 27 Nov 2014 13:56:58 +0100 Subject: [PATCH] re PR c++/63904 (ICE when accessing array member of constexpr struct) PR c++/63904 * g++.dg/cpp0x/pr63904.C: New. From-SVN: r218122 --- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/g++.dg/cpp0x/pr63904.C | 13 +++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 gcc/testsuite/g++.dg/cpp0x/pr63904.C diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 1bdaf1b9ef8..86af18c6c85 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2014-11-27 Kai Tietz + + PR c++/63904 + * g++.dg/cpp0x/pr63904.C: New. + 2014-11-27 Jakub Jelinek PR middle-end/64067 diff --git a/gcc/testsuite/g++.dg/cpp0x/pr63904.C b/gcc/testsuite/g++.dg/cpp0x/pr63904.C new file mode 100644 index 00000000000..2db610b472b --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/pr63904.C @@ -0,0 +1,13 @@ +// { dg-do compile { target c++11 } } + +template +struct foo { + constexpr foo() : a() {} + int a[N]; +}; + +int main() { + foo< (foo<1>{}).a[0] > f; + return 0; +} + -- 2.30.2