
Hi all, It's quite strange that I can't write something like that: ptr_vector<int> v; ptr_vector<int>::const_iterator i = v.begin(); //won't compile on VC7.1 ptr_vector<int>::iterator j = v.begin(); //It works ptr_vector<int>::ptr_const_iterator ip = v.ptr_begin(); //won't compile on VC7.1 ptr_vector<int>::ptr_iterator jp = v.ptr_begin(); //it works but const ptr_vector<int> cv; ptr_vector<int>::const_iterator k = cv.begin(); //works as expected ptr_vector<int>::const_iterator kp = cv.ptr_begin(); //works as expected but std::vector<int *> v2; std::vector<int *>::const_iterator = v2.begin(); //works just fine Obviously, this is a bug. -- Pavel Chikulaev

"Pavel Chikulaev" <pavel.chikulaev@gmail.com> wrote in message news:d1rmoe$9oa$1@sea.gmane.org... | Hi all, | | It's quite strange that I can't write something like that: | | ptr_vector<int> v; | | ptr_vector<int>::const_iterator i = v.begin(); //won't compile on VC7.1 | ptr_vector<int>::iterator j = v.begin(); //It works | | ptr_vector<int>::ptr_const_iterator ip = v.ptr_begin(); //won't compile on | VC7.1 | ptr_vector<int>::ptr_iterator jp = v.ptr_begin(); //it works | | but | | const ptr_vector<int> cv; | | ptr_vector<int>::const_iterator k = cv.begin(); //works as expected | ptr_vector<int>::const_iterator kp = cv.ptr_begin(); //works as expected | | but | | std::vector<int *> v2; | std::vector<int *>::const_iterator = v2.begin(); //works just fine | | Obviously, this is a bug. yes, thanks. I've comitted a fix.....a templated constructor in void_ptr_iterator...it only works for gcc at the moment...I don't know why vc7.1 can't accept it. Btw, Pavel, if you have additional comments on the post-review, please make them in the post-review thread. -Thorsten
participants (2)
-
Pavel Chikulaev
-
Thorsten Ottosen