From: Zdenek Dvorak Date: Wed, 11 Jan 2006 11:39:49 +0000 (+0100) Subject: re PR c++/25632 (ICE with const int copied into two different functions) X-Git-Tag: releases/gcc-4.2.0~4939 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c6c0cc813b0afee463086a70e7a21bca202926a7;p=thirdparty%2Fgcc.git re PR c++/25632 (ICE with const int copied into two different functions) PR c++/25632 * g++.dg/other/pr25632.C: New test. From-SVN: r109575 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index be973a022c44..d2aa0aa36101 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2005-01-11 Zdenek Dvorak + + PR c++/25632 + * g++.dg/other/pr25632.C: New test. + 2006-01-11 Paul Thomas PR fortran/25730 diff --git a/gcc/testsuite/g++.dg/other/pr25632.C b/gcc/testsuite/g++.dg/other/pr25632.C new file mode 100644 index 000000000000..a8884f6fc81d --- /dev/null +++ b/gcc/testsuite/g++.dg/other/pr25632.C @@ -0,0 +1,17 @@ +/* PR c++/25632 */ + +/* { dg-do compile } */ + +struct sockaddr_un { + char sun_path[1]; +}; +const unsigned SI_SUN_HEAD_LEN = (long)(((struct sockaddr_un *)0)->sun_path); +int SiGetPeerName () +{ + return SI_SUN_HEAD_LEN; +} +int SiAccept () +{ + return SI_SUN_HEAD_LEN; +} +