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]

Bug Report


Hello,

I received the following error while compiling sample code that follows.

Steve Gallo



(numenor)templates :>g++ test2.cc
test2.cc: In method `list::list()':
test2.cc:29: Internal compiler error 40.
test2.cc:29: Please submit a full bug report to `egcs-bugs@cygnus.com'.


----------  Sample program ----------

// Example program to reproduce compiler error in egcs
//
// Steven M. Gallo
// 9/30/98
//
// smgallo@numenor.csgeeks.org
// gallo@calspan.com


template <class T>
void
defaultDelete(void *del)
{
  T **d = (T **) del;
  delete del;
  *d = NULL;
}  // defaultDelete()



typedef void (*func_delete) (void *);

class list
{
private:
  func_delete deleteFunc_;

public:
  list() { deleteFunc_ = defaultDelete; }
  
};



int
main()
{


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