0_0_21465555_32261.cpp: In function 'int main()':
0_0_21465555_32261.cpp:39:33: error: no matching function for call to 'std::set<int>::erase(std::set<int>::reverse_iterator)'
a.erase(a.rbegin());
^
0_0_21465555_32261.cpp:39:33: note: candidates are:
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/set:61:0,
from 0_0_21465555_32261.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_set.h:590:7: note: std::set<_Key, _Compare, _Alloc>::iterator std::set<_Key, _Compare, _Alloc>::erase(std::set<_Key, _Compare, _Alloc>::const_iterator) [with _Key = int; _Compare = std::less<int>; _Alloc = std::allocator<int>; std::set<_Key, _Compare, _Alloc>::iterator = std::_Rb_tree_const_iterator<int>; std::set<_Key, _Compare, _Alloc>::const_iterator = std::_Rb_tree_const_iterator<int>]
erase(const_iterator __position)
^
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_set.h:590:7: note: no known conversion for argument 1 from 'std::set<int>::reverse_iterator {aka std::reverse_iterator<std::_Rb_tree_const_iterator<int> >}' to 'std::set<int>::const_iterator {aka std::_Rb_tree_const_iterator<int>}'
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_set.h:620:7: note: std::set<_Key, _Compare, _Alloc>::size_type std::set<_Key, _Compare, _Alloc>::erase(const key_type&) [with _Key = int; _Compare = std::less<int>; _Alloc = std::allocator<int>; std::set<_Key, _Compare, _Alloc>::size_type = long long unsigned int; std::set<_Key, _Compare, _Alloc>::key_type = int]
erase(const key_type& __x)
^
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_set.h:620:7: note: no known conversion for argument 1 from 'std::set<int>::reverse_iterator {aka std::reverse_iterator<std::_Rb_tree_const_iterator<int> >}' to 'const key_type& {aka const int&}'
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_set.h:642:7: note: std::set<_Key, _Compare, _Alloc>::iterator std::set<_Key, _Compare, _Alloc>::erase(std::set<_Key, _Compare, _Alloc>::const_iterator, std::set<_Key, _Compare, _Alloc>::const_iterator) [with _Key = int; _Compare = std::less<int>; _Alloc = std::allocator<int>; std::set<_Key, _Compare, _Alloc>::iterator = std::_Rb_tree_const_iterator<int>; std::set<_Key, _Compare, _Alloc>::const_iterator = std::_Rb_tree_const_iterator<int>]
erase(const_iterator __first, const_iterator __last)
^
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_set.h:642:7: note: candidate expects 2 arguments, 1 provided
|