OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc1/] [gcc/] [testsuite/] [g++.dg/] [eh/] [shadow1.C] - Diff between revs 301 and 338

Only display areas with differences | Details | Blame | View Log

Rev 301 Rev 338
// Copyright (C) 2004 Free Software Foundation, Inc.
// Copyright (C) 2004 Free Software Foundation, Inc.
// Contributed by Nathan Sidwell 15 Oct 2004 
// Contributed by Nathan Sidwell 15 Oct 2004 
// We forgot to ignore current context and friends when determing
// We forgot to ignore current context and friends when determing
// which exceptions shadowed eachother.
// which exceptions shadowed eachother.
struct E;
struct E;
struct B {};
struct B {};
struct D : private B
struct D : private B
{
{
  friend class E;
  friend class E;
  static B *baz (D *);
  static B *baz (D *);
  virtual void V () throw (B);  // { dg-error "overriding" "" }
  virtual void V () throw (B);  // { dg-error "overriding" "" }
};
};
struct E : public D
struct E : public D
{
{
  virtual void V () throw (D); // { dg-error "looser throw" "" }
  virtual void V () throw (D); // { dg-error "looser throw" "" }
};
};
B* foo (D *);
B* foo (D *);
B *D::baz (D *p)
B *D::baz (D *p)
{
{
  try {foo (p);}
  try {foo (p);}
  catch (B const &b) {}
  catch (B const &b) {}
  catch (D const &d) {}
  catch (D const &d) {}
  return p;
  return p;
}
}
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.