prog.cpp: In function ‘int main()’:
prog.cpp:6:23: error: variable ‘std::stringstream ss’ has initializer but incomplete type
std::stringstream ss(s);
^
prog.cpp:7:1: error: ‘istream_iterator’ is not a member of ‘std’
std::istream_iterator<std::string> begin(ss);
^
prog.cpp:7:34: error: expected primary-expression before ‘>’ token
std::istream_iterator<std::string> begin(ss);
^
prog.cpp:7:44: error: ‘begin’ was not declared in this scope
std::istream_iterator<std::string> begin(ss);
^
prog.cpp:8:1: error: ‘istream_iterator’ is not a member of ‘std’
std::istream_iterator<std::string> end;
^
prog.cpp:8:34: error: expected primary-expression before ‘>’ token
std::istream_iterator<std::string> end;
^
prog.cpp:8:36: error: ‘end’ was not declared in this scope
std::istream_iterator<std::string> end;
^
prog.cpp:9:1: error: ‘vector’ is not a member of ‘std’
std::vector<std::string> vstrings(begin, end);
^
prog.cpp:9:24: error: expected primary-expression before ‘>’ token
std::vector<std::string> vstrings(begin, end);
^
prog.cpp:9:45: error: ‘vstrings’ was not declared in this scope
std::vector<std::string> vstrings(begin, end);
^
prog.cpp:10:45: error: ‘ostream_iterator’ is not a member of ‘std’
std::copy(vstrings.begin(), vstrings.end(), std::ostream_iterator<std::string>(std::cout, "\n"));
^
prog.cpp:10:78: error: expected primary-expression before ‘>’ token
std::copy(vstrings.begin(), vstrings.end(), std::ostream_iterator<std::string>(std::cout, "\n"));
^
prog.cpp:10:91: warning: left operand of comma operator has no effect [-Wunused-value]
std::copy(vstrings.begin(), vstrings.end(), std::ostream_iterator<std::string>(std::cout, "\n"));
^