public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/17076] New: ICE on variable size array initialization in debug mode in C++
@ 2004-08-18  9:42 kunegis at cs dot tu-berlin dot de
  2004-10-15 10:06 ` [Bug debug/17076] [3.4 regression] " reichelt at gcc dot gnu dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: kunegis at cs dot tu-berlin dot de @ 2004-08-18  9:42 UTC (permalink / raw)
  To: gcc-bugs

An internal compiler error in G++ version 3.4.1 in debug mode using variable
size arrays.  The size of the array is taken from the member of a struct that is
returned by a function.  The source is in preprocessed C++.  

----------BEGIN FILE bug.ii---------
struct Integer
{
	int x;
};

Integer f()
{
	return (Integer){45};
}

int main()
{
	int numbers[f().x];
	return 0;
}
------END FILE bug.ii-----------

Sample session:

$ g++ bug.ii
$ g++ -g bug.ii
bug.ii: In function `int main()':
bug.ii:15: internal compiler error: in loc_descriptor_from_tree, at dwarf2out.c:8863
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
$ gcc --version
gcc (GCC) 3.4.1

Notes:
-When compiled as the file "bug.i" using "gcc", no ICE happens and the compiler
reports an error.
-I don't know whether the code is correct.
-The ICE could not be reproduced in gcc 3.3.3 on i686-suse-linux.

-- 
           Summary: ICE on variable size array initialization in debug mode
                    in C++
           Product: gcc
           Version: 3.4.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: kunegis at cs dot tu-berlin dot de
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: sparc-sun-solaris2.9
  GCC host triplet: sparc-sun-solaris2.9
GCC target triplet: sparc-sun-solaris2.9


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17076


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2006-02-28  9:40 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-17076-9160@http.gcc.gnu.org/bugzilla/>
2005-10-07  3:28 ` [Bug debug/17076] [3.4 regression] ICE on variable size array initialization in debug mode in C++ gdr at gcc dot gnu dot org
2006-02-28  9:40 ` gdr at gcc dot gnu dot org
2004-08-18  9:42 [Bug c/17076] New: " kunegis at cs dot tu-berlin dot de
2004-10-15 10:06 ` [Bug debug/17076] [3.4 regression] " reichelt at gcc dot gnu dot org
2004-10-16 14:24 ` reichelt at gcc dot gnu dot org
2004-11-01  0:47 ` mmitchel at gcc dot gnu dot org
2005-05-19 17:36 ` mmitchel at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).