requesting help for g++/gcc v3.2 on redhat Linux8.0.
RAMU MEDA (HP INDIA ,Bangalore)
mramu@india.hp.com
Mon Dec 9 21:32:00 GMT 2002
Hi ,
>
> REQUEST 1:
requesting help for g++/gcc v3.2 on redhat Linux8.0(intel).
> The errors we got for test.cpp are listed below.
> we request for your inputs, if any ,to solve the problem.
> ( For your information, same code is working fine on g++ v2.96)
>
> REQUEST 2:
Also , what is the option on gcc for : "Turns on newly supported ANSI C++
Standard features
like namespace std and the new C++ Standard Library"? please let us know.
>
> =================test.cpp========================
> #include <vector>
>
> using namespace std;
> class a
> {
> };
>
> class b : public a
> {
> };
>
> int main()
> {
> vector<a*> v;
> vector<b*>::iterator listiterator;
> typedef vector<b*>::iterator biter;
> listiterator=(biter) (v.begin());
> }
> ===========================================
> ERRORS for g++ test.cpp
> =============================================
>
> test.cpp: In function `int main()':
> test.cpp:17: no matching function for call to `
> __gnu_cxx::__normal_iterator<b**, std::vector<b*, std::allocator<b*> >
> >::
> __normal_iterator(__gnu_cxx::__normal_iterator<a**, std::vector<a*,
> std::allocator<a*> > >)'
> /usr/include/c++/3.2/bits/stl_iterator.h:571: candidates are:
> __gnu_cxx::__normal_iterator<b**, std::vector<b*, std::allocator<b*> >
> >::__normal_iterator(const __gnu_cxx::__normal_iterator<b**,
> std::vector<b*,
> std::allocator<b*> > >&)
> /usr/include/c++/3.2/bits/stl_iterator.h:584:
> __gnu_cxx::__normal_iterator<_Iterator,
> _Container>::__normal_iterator(const
> _Iterator&) [with _Iterator = b**, _Container = std::vector<b*,
> std::allocator<b*> >]
> /usr/include/c++/3.2/bits/stl_iterator.h:581:
> __gnu_cxx::__normal_iterator<_Iterator,
_Container>::__normal_iterator()
> [with _Iterator = b**, _Container = std::vector<b*, std::allocator<b*>
>]
> =================================================
>
Regards,
Ramu Meda
29, Hewlett Packard ISO
Cunningham Road, Bangalore
Phone (o): (91) (80) 2051181 (Direct)
Email (p) : ramumeda@yahoo.com
More information about the Gcc-help
mailing list