🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Larry Ketcham Wed, 29 Nov 1989 22:25
Segmentation fault in G++ 1.36.1
#642
Author: Larry Ketcham
Date: Wed, 29 Nov 1989 22:25
37 lines
1700 bytes
Is a fix available for this problem?

The following program fragment gets a segmentation fault in G++ 1.36.1:

------------------test_const.cc------------------------------------------
struct A
  { 
    int a;
    A(int new_a) { }
  };

struct B
  { 
    A A_item;
    B()
      { 
	A_item = A(0);    // this line bombs GNU C++
      };
  };
-------------------------------------------------------------------------

-------------------------------------------------------------------------
g++-new -v test_const.cc
gcc version 1.36.1m1 (based on GCC 1.36)
 /usr/local/src/lib/sun3/g++-1.36.1m1/gcc-cpp -+ -v -undef -D__GNUC__ 
-D__GNUG__ -D__cplusplus -Dmc68000 -Dsun -Dunix -D__mc68000__ -D__sun__
-D__unix__ -D__HAVE_68881__ -Dmc68020 test_const.cc /usr/tmp/cca20399.cpp
GNU CPP version 1.36
 /usr/local/src/lib/sun3/g++-1.36.1m1/gcc-cc1plus /usr/tmp/cca20399.cpp 
-quiet -dumpbase test_const.cc -version -o /usr/tmp/cca20399.s
GNU C++ version 1.36.1m1 (based on GCC 1.36) (68k, MIT syntax) compiled 
 by GNU C version 1.36.
default target switches: -m68020 -mc68020 -m68881 -mbitfield
test_const.cc: In method B::B ():
test_const.cc:12: Segmentation violation
g++-new: Program cc1plus got fatal signal 11.
-------------------------------------------------------------------------
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads