Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-21 Thread Paolo Carlini
On 11/21/2011 03:05 AM, Jason Merrill wrote: On 11/20/2011 08:02 PM, Paolo Carlini wrote: .. also, I was under the impression that c++/48322 was the only reason we couldn't write something very simple, thus no __all_convertible, ie, something using directly: enable_if<__and_...>::value>::type

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Daniel Krügler
2011/11/21 Daniel Krügler : > 2011/11/21 Jason Merrill : >> On 11/20/2011 08:02 PM, Paolo Carlini wrote: >>> >>> .. also, I was under the impression that c++/48322 was the only reason >>> we couldn't write something very simple, thus no __all_convertible, ie, >>> something using directly: >>> >>> e

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Daniel Krügler
2011/11/21 Paolo Carlini : > On 11/21/2011 01:22 AM, Jason Merrill wrote: >> >> This bug fix required the following change to >> libstdc++-v3/include/std/tuple: >> >>> -      template>> -       enable_if<__and_>> -                                          == sizeof...(_Elements)>, >>> -            

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Daniel Krügler
2011/11/21 Jason Merrill : > On 11/20/2011 08:02 PM, Paolo Carlini wrote: >> >> .. also, I was under the impression that c++/48322 was the only reason >> we couldn't write something very simple, thus no __all_convertible, ie, >> something using directly: >> >> enable_if<__and_...>::value>::type > >

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Jason Merrill
On 11/20/2011 08:02 PM, Paolo Carlini wrote: .. also, I was under the impression that c++/48322 was the only reason we couldn't write something very simple, thus no __all_convertible, ie, something using directly: enable_if<__and_...>::value>::type Yep, you can do that now. That would be a g

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Jason Merrill
On 11/20/2011 07:22 PM, Jason Merrill wrote: Hmm, actually, that still shouldn't have produced an error, it should just SFINAE. Another bug to fix... Thus. Tested x86_64-pc-linux-gnu, applying to trunk. commit 9c48487dc4ba1a0fd3235b03a00930379a8e7620 Author: Jason Merrill Date: Sun Nov 20

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Paolo Carlini
.. also, I was under the impression that c++/48322 was the only reason we couldn't write something very simple, thus no __all_convertible, ie, something using directly: enable_if<__and__Elements>...>::value>::type That would be a great improvement, even if we need to SFINAE separately fo

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Paolo Carlini
On 11/21/2011 01:22 AM, Jason Merrill wrote: This bug fix required the following change to libstdc++-v3/include/std/tuple: - template, -__all_convertible<__conv_types<_UElements...>, - __conv_types<_Elements...>> - >::value>

Re: C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Jason Merrill
This bug fix required the following change to libstdc++-v3/include/std/tuple: - template, -__all_convertible<__conv_types<_UElements...>, - __conv_types<_Elements...>> ->::value>::type> + template

C++ PATCH for c++/48322 (broken handling of variadic parms on multiple levels)

2011-11-20 Thread Jason Merrill
Under this bug, given something like template struct A { template ...> > static void f(); }; When we instantiate A, we partially instantiate f. But since we don't have all the Us, we can't instantiate pair... at all yet. Before this patch we incorrectly modified it so that it ended up b