1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
| 08-08-09.c:4: error: variable 'std::string s' has initializer but incomplete type
08-08-09.c:6: error: no matching function for call to 'std::vector<std::string, std::allocator<std::string> >::push_back(<type error>)'
/usr/include/c++/4.0.0/bits/stl_vector.h:602: note: candidates are: void std::vector<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = std::string, _Alloc = std::allocator<std::string>]
/usr/include/c++/4.0.0/bits/stl_vector.h: In destructor 'std::_Vector_base<_Tp, _Alloc>::~_Vector_base() [with _Tp = std::string, _Alloc = std::allocator<std::string>]':
/usr/include/c++/4.0.0/bits/stl_vector.h:189: instantiated from 'std::vector<_Tp, _Alloc>::vector(const typename std::_Vector_base<_Tp, _Alloc>::allocator_type&) [with _Tp = std::string, _Alloc = std::allocator<std::string>]'
08-08-09.c:5: instantiated from here
/usr/include/c++/4.0.0/bits/stl_vector.h:109: error: invalid use of undefined type 'struct std::string'
/usr/include/c++/4.0.0/bits/stringfwd.h:56: error: declaration of 'struct std::string'
/usr/include/c++/4.0.0/bits/stl_construct.h: In function 'void std::_Destroy(_ForwardIterator, _ForwardIterator, _Allocator) [with _ForwardIterator = std::string*, _Allocator = std::allocator<std::string>]':
/usr/include/c++/4.0.0/bits/stl_vector.h:273: instantiated from 'std::vector<_Tp, _Alloc>::~vector() [with _Tp = std::string, _Alloc = std::allocator<std::string>]'
08-08-09.c:5: instantiated from here
/usr/include/c++/4.0.0/bits/stl_construct.h:173: error: cannot increment a pointer to incomplete type 'std::string'
/usr/include/c++/4.0.0/ext/new_allocator.h: In member function 'void __gnu_cxx::new_allocator<_Tp>::destroy(_Tp*) [with _Tp = std::string]':
/usr/include/c++/4.0.0/bits/stl_construct.h:174: instantiated from 'void std::_Destroy(_ForwardIterator, _ForwardIterator, _Allocator) [with _ForwardIterator = std::string*, _Allocator = std::allocator<std::string>]'
/usr/include/c++/4.0.0/bits/stl_vector.h:273: instantiated from 'std::vector<_Tp, _Alloc>::~vector() [with _Tp = std::string, _Alloc = std::allocator<std::string>]'
08-08-09.c:5: instantiated from here
/usr/include/c++/4.0.0/ext/new_allocator.h:107: error: invalid use of undefined type 'struct std::basic_string<char, std::char_traits<char>, std::allocator<char> >'
/usr/include/c++/4.0.0/bits/stringfwd.h:56: error: declaration of 'struct std::basic_string<char, std::char_traits<char>, std::allocator<char> >' |
Partager