Compiler output
prog.cpp: In function 'int main()':
prog.cpp:51:9: error: reference to 'next' is ambiguous
next.lin=lin(c); next.col=col(c);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:51:26: error: reference to 'next' is ambiguous
next.lin=lin(c); next.col=col(c);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:52:28: error: reference to 'next' is ambiguous
dist_st=max(st.lin,next.lin)-min(st.lin,next.lin)+max(st.col,next.col)-min(st.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:52:49: error: reference to 'next' is ambiguous
dist_st=max(st.lin,next.lin)-min(st.lin,next.lin)+max(st.col,next.col)-min(st.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:52:70: error: reference to 'next' is ambiguous
dist_st=max(st.lin,next.lin)-min(st.lin,next.lin)+max(st.col,next.col)-min(st.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:52:91: error: reference to 'next' is ambiguous
dist_st=max(st.lin,next.lin)-min(st.lin,next.lin)+max(st.col,next.col)-min(st.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:53:28: error: reference to 'next' is ambiguous
dist_dr=max(dr.lin,next.lin)-min(dr.lin,next.lin)+max(dr.col,next.col)-min(dr.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:53:49: error: reference to 'next' is ambiguous
dist_dr=max(dr.lin,next.lin)-min(dr.lin,next.lin)+max(dr.col,next.col)-min(dr.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:53:70: error: reference to 'next' is ambiguous
dist_dr=max(dr.lin,next.lin)-min(dr.lin,next.lin)+max(dr.col,next.col)-min(dr.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:53:91: error: reference to 'next' is ambiguous
dist_dr=max(dr.lin,next.lin)-min(dr.lin,next.lin)+max(dr.col,next.col)-min(dr.col,next.col);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:55:21: error: reference to 'next' is ambiguous
swap(st,next);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^
prog.cpp:57:21: error: reference to 'next' is ambiguous
swap(dr,next);
^
prog.cpp:9:13: note: candidates are: tasta next
tasta st,dr,next;
^
In file included from /usr/include/c++/4.9/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.9/bits/char_traits.h:39,
from /usr/include/c++/4.9/ios:40,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from prog.cpp:2:
/usr/include/c++/4.9/bits/stl_iterator_base_funcs.h:184:5: note: template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
next(_ForwardIterator __x, typename
^