This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292

--- Comment #2 from Nathan Ridge <zeratul976 at hotmail dot com> 2011-03-26 00:02:32 UTC ---
Found a workaround:

#include <type_traits>

template <typename... Args> 
int g(Args...);

template <typename... Args>
struct deduce
{
    typedef decltype(g(std::declval<Args>()...)) type;
};

template <int N = 0>
struct A
{
    template <typename... Args>
    static typename deduce<Args...>::type f(Args... args);
};

int main()
{
    A<>::f();
    return 0;
}


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]