Suppose I have two structs:
struct
struct X {}; struct Y { X x; }
I have functions:
void f(X&); void f(X&&
I think this will work, although I'm not sure:
template struct mforward { using type = M&&; }; template struct mforward { using type = M&; }; template void g(T&& t) { f(std::forward::type>(t.x)); }