🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.g++.bug
Article #35

program cc1plus got fatal signal 11

#35
From: seidl
Date: Tue, 03 Nov 1992 12:32
80 lines
2428 bytes
Help! Given the following code, g++ 2.3.1 gave the following error:

gcc -c foo.cc
gcc: Internal compiler error: program cc1plus got fatal signal 11


I am running SunOS 4.1.1.  I compiled gcc right out of the box, using
gcc 2.2.2 to make the stage1 compiler, and then made stage 2 with

  gmake CC="stage1/xgcc -Bstage1/" CFLAGS=-O

I finally installed stage3, which was compiled with

  gmake CC="stage2/xgcc -Bstage2/" CFLAGS=-O

There were no diffs between stage2 and stage3.

This will compile with gcc 2.2.2, and will compile if the second constructor
for ClassKey() is commented out. It will also compile if GNUBUG is defined.

Here is foo.cc:
============================

class ClassKeyClassDescPMap;
class ClassKeySet;
class DescribedClass;

class ClassKey {
  public:
    ClassKey(const char* name);
    ClassKey(ClassKey&);
  };

class ClassDesc {
  private:
    ClassKeySet* string_to_parents(ClassKey&,const char*);
    static ClassKeyClassDescPMap* all_;
    ClassKeySet* parents_;
    ClassKeySet* children_;
  public:
    ~ClassDesc();
  };

typedef ClassDesc* ClassDescP;

class ClassKeyClassDescPMap {
public:
  virtual ClassDescP&          operator [] (ClassKey  key) = 0;
};

class ClassKeySet {
public:
  virtual int add(ClassKey  item) = 0;
};


//////////////////////////////////////////////////////////////

ClassKeyClassDescPMap* ClassDesc::all_;

ClassKeySet* ClassDesc::string_to_parents(ClassKey&key,const char*parents)
{
  char* token;
  ClassKey parentkey(token);
#ifndef GNUBUG
  ((*all_)[parentkey]->children_)->add(key);
#else
  ClassKeySet *ppp=(*all_)[parentkey]->children_;
  ppp->add(key);
#endif

  return parents_;
  }


-- 
Edward Seidl                                      DCRT/CSL Bldg 12A, Rm 2033
seidl@alw.nih.gov                                 NIH, Bethesda, MD 20892  

I'm not paid enough to have an opinion, much less express one for my employer.
Technical Details
Message-ID: <9211031232.AA20306@midway.dcrt.nih.gov>
Path: arc1-ca.pugleaf.net!sparky!uunet!news.encore.com!csar!foxtail!sdd.hp.com!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!alw.nih.gov!seidl

Show Full Headers
Complete Article Headers
Newsgroups: gnu.g++.bug
Path: arc1-ca.pugleaf.net!sparky!uunet!news.encore.com!csar!foxtail!sdd.hp.com!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!alw.nih.gov!seidl
From: seidl@alw.nih.gov
Subject: program cc1plus got fatal signal 11
Message-ID: <9211031232.AA20306@midway.dcrt.nih.gov>
Sender: gnulists@ai.mit.edu
Organization: National Institutes of Health
Distribution: gnu
Date: Tue, 3 Nov 1992 12:32:01 GMT
Approved: bug-g++@prep.ai.mit.edu
Lines: 81