Internal compiler error using g++ 970924

Bernd Nottelmann nottelm@ptp283.uni-muenster.de
Sat Sep 27 04:08:00 GMT 1997


Hi!

(I have reported this bug a few days ago, but perhaps the subject
was mistakable.)
The error occured compiling the following code with gcc -O[2] -c:

------------snip-----------
class string
{
public:
    string();
    string(const string& x);
    string(const char* t);

    ~string();
};

void set_status(string message);

class StatusDelay {
private:
    string cause;

public:
    StatusDelay(const string& c)
        : cause(c)
    {
        set_status(cause);
    }

    ~StatusDelay()
    {
        set_status(cause);
    }
};

static char delay_message[] = "Filtering files";

static void searchRemote()
{
    StatusDelay delay(delay_message);
    return;
}
------------snip-----------
g++ -c -O[2] foo.C
foo.C: In function `void searchRemote()':
foo.C:36: Internal compiler error.
foo.C:36: Please submit a full bug report to `egcs-bugs@cygnus.com'.

Without optimization it compiles fine.

My configuration:
linux-2.0.30, libc.so.5.4.39, libg++.so.27.2.8, libstdc++.so.27.2.8

gcc -v
Reading specs from
/usr/lib/gcc-lib/i686-pc-linux-gnulibc1/egcs-2.90.10/specs
gcc version egcs-2.90.10 970924 (gcc2-970802 experimental)

Bernd





More information about the Gcc-bugs mailing list