This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/21275] gcc 4.0.0 crash with mingw when using stdout in global var
- From: "dannysmith at users dot sourceforge dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 30 Apr 2005 09:08:42 -0000
- Subject: [Bug c/21275] gcc 4.0.0 crash with mingw when using stdout in global var
- References: <20050429054610.21275.ch.ehrlicher@gmx.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From dannysmith at users dot sourceforge dot net 2005-04-30 09:08 -------
Oops, I reduced the code in comment #1 too much. This shows the problem.
//dllimport_array.C
// This causes 'initializer element is not constant' error in C,
// static_initialization_and_destruction code in C++
extern __attribute__ ((dllimport)) int* foo1;
int* k = &foo1[0];
// This causes 'initializer element is not constant' error in C,
// ICE in C++
extern __attribute__ ((dllimport)) int foo2[];
int* j = &foo2[0];
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |dannysmith at users dot
| |sourceforge dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21275