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 middle-end/50741] [4.7 Regression] remove_unused_locals causes seg fault


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

--- Comment #4 from Michael Matz <matz at gcc dot gnu.org> 2011-10-17 15:18:08 UTC ---
Reducable to:
% cat x.cc
struct PublishLo
{
  const char *functionName;
  ~PublishLo();
};
struct A { A(); };
A::A()
{
  static PublishLo _rL_53 = {__FUNCTION__};
}

The problem doesn't happen when A::A is instead a normal top-level function,
which leads me to believe that somehow for member functions something forgets
to walk the initializers in add_referenced_var.


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