summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.pt/partial3.C
blob: f62f915663995ad741529a1fbc44dcd5101eac46 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// { dg-do run  }
// Test that partial ordering works between conversion ops from different
// classes.
// From Jason Merrill <jason@cygnus.com>

struct A {
  template <class T> operator T*() { return 0; }
};
struct B : public A {
  template <class T> operator T();
};

int main()
{
  B b;
  (void*) b;
}