This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: c++/8564: internal compiler error in find_function_data, at function.c:329 with g++ 3.2


Synopsis: internal compiler error in find_function_data, at function.c:329 with  g++ 3.2

State-Changed-From-To: open->analyzed
State-Changed-By: reichelt
State-Changed-When: Thu Nov 14 01:59:16 2002
State-Changed-Why:
    Confirmed.
    
    The bug can be demonstrated with the following code snippet:
    
    ----------------------------snip here--------------------------
    class A { static char* p; };
    
    int i = 1;
    char* A::p = new char[i];
    
    class B { B(); };
    
    B::B() {}
    ----------------------------snip here--------------------------
    
    This crashes gcc 3.0.x, 3.1 - 3.2.1, and mainline (just compile with
    g++ -c) - with gcc 2.95.x, however, the code compiles fine.
    So this is a regression from 2.95.x.
    
    A workaround is to write "new char[1]" instead of "new char[i]"
    (i.e. replace line 29675 by
      char* SpParmSetDataItem::ret = new char[30];
    in the file jj.C).

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8564


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]