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]

[Bug c++/13170] [3.4 Regression] ICE in build_base_path


------- Additional Comments From bangerth at dealii dot org  2003-11-24 17:33 -------
OK, here's a reduced testcase:
---------------------
struct __attribute__((dllimport)) Base {
  virtual inline ~Base() {}
};

struct __attribute__((dllimport)) Derived : public Base {
  bool operator== (const Derived& text);
  bool foo(const Derived &);
};


bool Derived::foo(const Derived &) {
  return 1;
}

bool Derived::operator== (const Derived& text) {
  return foo(text);
}
--------------------------------

g/x> /home/bangerth/bin/gcc-3.4-pre/bin/c++ -c x.cc
x.cc:3: warning: `dllimport' attribute directive ignored
x.cc:8: warning: `dllimport' attribute directive ignored
x.cc: In member function `bool Derived::operator==(const Derived&)':
x.cc:16: internal compiler error: in build_base_path, at cp/class.c:278
Please submit a full bug report,

The ICE goes away if I remove the attributes. Interestingly, we
seem to replace the ICE by an infinite loop if we remove the
destructor of the base class...

W.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13170


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