Noah Roberts | 22 May 17:47

Re: tuple type question

Daniel Krügler wrote:

> #include <utility>
> 
> template <typename>
> struct TT {
>    typename std::pair<int, double>::first_type name() {
>      return 0;
>    }
> };
> 
> int main() {
>    return TT<void>().name();
> }
> 
> If the compiler does not accept the typename here, it is
> broken, which was the essence of my OP.

I see.  Yeah, it was a bit hard to track what was going on with the OP's 
code.

Gmane