1 /* { dg-do compile } */
2 /* { dg-options "-O3 -c -w" } */
4 template <class> class A;
5 template <class R> struct VirtualMatrice {
6 virtual bool m_fn1(int) const { return true; }
9 B(VirtualMatrice *p1, A<R> p2) : x(p2) { p1->m_fn1(0) ?: throw; }
11 void operator*(A<R> p1) { B(this, p1); }
15 template <class> class A {
21 class G : public A<int> {
26 template <class> class H : VirtualMatrice<int> {};
27 template <class> class C;
28 template <> class C<int> : H<Complex>, VirtualMatrice<Complex> {
29 bool m_fn1(int) const { return true; }
31 template <class K, class Mat>
32 void DoIdoAction(int, int, A<K> p3, A<K>, A<K>, A<K>, Mat, Mat &p8) {
39 int operator()() const;
42 int D::F::operator()() const {
44 VirtualMatrice<K> b, &B = *a;
47 A<K> h(&g[f], 0), i(&g[e], 0), j(&g[d], 0);
48 DoIdoAction(0, 3, h, i, j, c, b, B);