------- Comment #2 from igodard at pacbell dot net  2005-10-30 21:29 -------
I don't get it. The argument is A<int>::iterator, which surely depends on
A<E>::iterator (with "E" taken as "int"). The problem also arises in the
simpler case:
#include <iostream>

template<typename E>
class A {
public:
    class iterator {
        E dummy;
        };
    iterator iter;
    };

template< typename E>
void sort( typename E::iterator& first, typename E::iterator& last ) {
    std::cout << "sort" << std::endl;
    }

int main( int argc, char *argv[] ) {
    A<int> first, last;
    sort(first.iter,last.iter);
    return 0;
    }

It looks to me that unification is not looking at the qualifier of a qualified
type. This may be what the standard says (it's a mystery to me) but is sure
surprising.

Ivan


-- 


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

Reply via email to