This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/69978] Invalid sizeof... value for variadic template arguments
- From: "yanikibo at yandex dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 26 Feb 2016 13:07:38 +0000
- Subject: [Bug c++/69978] Invalid sizeof... value for variadic template arguments
- Auto-submitted: auto-generated
- References: <bug-69978-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69978
--- Comment #2 from Ibrahim Gokhan YANIKLAR <yanikibo at yandex dot com> ---
template < class T, class U, class... TL >
void goo( T, U, TL... )
{
std::cout << (B<T, U, TL...>::value) << std::endl;
std::cout << (D<T, U, TL...>::value) << std::endl;
std::cout << (C< B<T, U, TL...> >::type::value << std::endl;
}
int main()
{
goo(10, 20, 30, 40, 50);
}
//-----------------------
// output(g++4.7):
//-----------------------
// 3
// 3
// 3
//-----------------------
// output(g++4.8-g++5.2):
//-----------------------
// 5
// 5
// 3
//-----------------------
// output(correct)
//-----------------------
// 5
// 5
// 5