struct X { int v; typedef int t; }; struct YA { int value; typedef int type; }; template struct C : X, T { using T::value; using typename T::type; using X::v; using typename X::t; }; template struct D : X, T { using T::value; using typename T::type; using X::v; using typename X::t; }; template struct E : X, T { using T::value; using typename T::type; using X::v; using typename X::t; }; template struct F : X, T { using T::value; using typename T::type; using X::v; using typename X::t; }; // Force instantiation. typedef C::type I; typedef D::type I; typedef E::type I; typedef F::type I;