From 663cea5dc02ebf8a4b6d34c574e55544d747519d Mon Sep 17 00:00:00 2001 From: Giovanni Bajo Date: Thu, 8 Jan 2004 11:57:53 +0000 Subject: re PR c++/12573 (ICE (segfault) with Boost.Python) PR c++/12573 * g++.dg/template/dependent-expr4.C: New test. From-SVN: r75547 --- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/g++.dg/template/dependent-expr4.C | 14 ++++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 gcc/testsuite/g++.dg/template/dependent-expr4.C (limited to 'gcc') diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 778a82e..bedd6da 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2004-01-08 Giovanni Bajo + + PR c++/12573 + * g++.dg/template/dependent-expr4.C: New test. + 2004-01-08 Hartmut Penner * gcc.dg/altivec-11.c: New test. diff --git a/gcc/testsuite/g++.dg/template/dependent-expr4.C b/gcc/testsuite/g++.dg/template/dependent-expr4.C new file mode 100644 index 0000000..066436b --- /dev/null +++ b/gcc/testsuite/g++.dg/template/dependent-expr4.C @@ -0,0 +1,14 @@ +// { dg-do compile } +// Origin: jbrandmeyer at users dot sourceforge dot net +// PR c++/12573: COMPONENT_REFs must be inspected for dependness. + +template struct S; + +template struct Y { + int x; +}; + +template struct Z { + S< (bool)(__offsetof__(&static_cast*>(0)->x) == 0) > + s; +}; -- cgit v1.1