foo.cpp: In function 'int main()':
foo.cpp:5:21: error: no match for 'operator+' in 'std::cin + std::cin'
foo.cpp:5:21: note: candidates are:
In file included from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/stl_algobase.h:68:0,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/char_traits.h:41,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ios:41,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ostream:40,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/iostream:40,
from foo.cpp:1:
c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/stl_iterator.h:335:5: note: template<class _Iterator> std::reverse_iterator<_Iterator> std::operator+(typename std::reverse_iterator<_Iterator>::difference_type, const std::reverse_iterator<_Iterator>&)
c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/stl_iterator.h:335:5: note: template argument deduction/substitution failed:
foo.cpp:5:21: note: 'std::istream {aka std::basic_istream<char>}' is not derived from 'const std::reverse_iterator<_Iterator>'
In file included from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/string:54:0,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/locale_classes.h:42,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/ios_base.h:43,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ios:43,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ostream:40,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/iostream:40,
from foo.cpp:1:
c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/basic_string.h:2362:5: note: template<class _CharT, class _Traits, class _Alloc> std::basic_string<_CharT, _Traits, _Alloc> std::operator+(const std::basic_string<_CharT, _Traits, _Alloc>&, const std::basic_string<_CharT, _Traits, _Alloc>&)
c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/basic_string.h:2362:5: note: template argument deduction/substitution failed:
foo.cpp:5:21: note: 'std::istream {aka std::basic_istream<char>}' is not derived from 'const std::basic_string<_CharT, _Traits, _Alloc>'
In file included from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/string:55:0,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/locale_classes.h:42,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/ios_base.h:43,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ios:43,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ostream:40,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/iostream:40,
from foo.cpp:1:
c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/basic_string.tcc:694:5: note: template<class _CharT, class _Traits, class _Alloc> std::basic_string<_CharT, _Traits, _Alloc> std::operator+(const _CharT*, const std::basic_string<_CharT, _Traits, _Alloc>&)
c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/basic_string.tcc:694:5: note: template argument deduction/substitution failed:
foo.cpp:5:21: note: mismatched types 'const _CharT*' and 'std::basic_istream<char>'
In file included from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/string:55:0,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/locale_classes.h:42,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/ios_base.h:43,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ios:43,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/ostream:40,
from c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/iostream:40,
from foo.cpp:1:
c:\mingw32\bin\../lib/gcc/mingw32/4.7.1/include/c++/bits/basic_string.tcc:710:5: note: template<class _CharT, class _Traits, class _Alloc