[Bug c++/46719] [C++0x] Cannot call variadic function template
redi at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Nov 30 10:57:00 GMT 2010
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46719
--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> 2010-11-30 10:36:42 UTC ---
Reduced to get rid of library dependencies:
template <typename Return, typename... ArgTypes>
struct function
{
template<typename Functor> function(Functor) { }
};
template <typename Return, typename FirstType, typename... ArgTypes>
int
curry(function<Return(FirstType,ArgTypes...)> func, FirstType)
{
return 0;
}
int main()
{
return curry( [](int x) -> double { return static_cast<double>(x); }, 10 );
}
More information about the Gcc-bugs
mailing list