isthisreallyit
Programmer
Hi,
All the examples I am trying, using, istream_iterator, do not work.
I get crappy error messages, like ....
error C2440: 'type cast' : cannot convert from 'istream_withassign' to 'std::istream_iterator<_Ty,_Elem,_Traits,_Diff>'
with
[
_Ty=int,
_Elem=char,
_Traits=std::char_traits<char>,
_Diff=ptrdiff_t
]
All I am doing, is using a simple example ...
vector<int> V;
std::copy(istream_iterator<int>(cin),
istream_iterator<int>(),
back_inserter(V));
2 lines, and it still screws-up??? I'm using Visual Studio.NET.
Any suggestions please
All the examples I am trying, using, istream_iterator, do not work.
I get crappy error messages, like ....
error C2440: 'type cast' : cannot convert from 'istream_withassign' to 'std::istream_iterator<_Ty,_Elem,_Traits,_Diff>'
with
[
_Ty=int,
_Elem=char,
_Traits=std::char_traits<char>,
_Diff=ptrdiff_t
]
All I am doing, is using a simple example ...
vector<int> V;
std::copy(istream_iterator<int>(cin),
istream_iterator<int>(),
back_inserter(V));
2 lines, and it still screws-up??? I'm using Visual Studio.NET.
Any suggestions please