How can I get access to the individual items in a parameter pack?
Given the following:
template<typename T>
struct X {};
template<class R, class... Args>
struct X<R (Args...)>
{
// how can I create a typedef for the first parameter
// basically I want to do something like if arg1 exists typedef it
// pseduo code below
if (Args[0])
typedef typename Args[0] Parameter1
}
Otherwise I might have to do something like this but was hoping to keep it generic
template<class R, class... Args>
struct X<R (Arg1, Args...)>
{
}