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/] [template/] [overload1.C] - Diff between revs 301 and 338

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

Rev 301 Rev 338
// { dg-options "-w" }
// { dg-options "-w" }
// PR c++/9420
// PR c++/9420
// Bug: We were instantiating B during overload resolution for E<0.
// Bug: We were instantiating B during overload resolution for E<0.
// This is wrong; the contents of B are not relevant, since we can't
// This is wrong; the contents of B are not relevant, since we can't
// use its constructors (because we'd already be using a constructor for
// use its constructors (because we'd already be using a constructor for
// C).
// C).
enum { E };
enum { E };
template  struct A {
template  struct A {
  static const int a = (E < 0);
  static const int a = (E < 0);
};
};
template  class B {
template  class B {
  A b;
  A b;
};
};
struct C {
struct C {
  C(B);
  C(B);
};
};
int operator<(C, C);
int operator<(C, C);
A c;
A c;
 
 

powered by: WebSVN 2.1.0

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