0_0_17746626_6612.cpp: In instantiation of 'TreeNode* buildTree(II, II) [with II = __gnu_cxx::__normal_iterator<int*, std::vector<int> >]':
0_0_17746626_6612.cpp:230:62: required from here
0_0_17746626_6612.cpp:198:23: error: call of overloaded 'next(__gnu_cxx::__normal_iterator<int*, std::vector<int> >&)' is ambiguous
II i = next(pre_first);
^
0_0_17746626_6612.cpp:198:23: note: candidates are:
0_0_17746626_6612.cpp:120:4: note: II next(II) [with II = __gnu_cxx::__normal_iterator<int*, std::vector<int> >]
II next(II begin)
^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:66:0,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/vector:60,
from 0_0_17746626_6612.cpp:114:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:184:5: note: _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type) [with _ForwardIterator = __gnu_cxx::__normal_iterator<int*, std::vector<int> >; typename std::iterator_traits<_Iter>::difference_type = long long int]
next(_ForwardIterator __x, typename
^
0_0_17746626_6612.cpp:206:41: error: call of overloaded 'next(__gnu_cxx::__normal_iterator<int*, std::vector<int> >&)' is ambiguous
root->left = buildTree(next(pre_first), next(pre_first, leftSize + 1));
^
0_0_17746626_6612.cpp:206:41: note: candidates are:
0_0_17746626_6612.cpp:120:4: note: II next(II) [with II = __gnu_cxx::__normal_iterator<int*, std::vector<int> >]
II next(II begin)
^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:66:0,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/vector:60,
from 0_0_17746626_6612.cpp:114:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:184:5: note: _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type) [with _ForwardIterator = __gnu_cxx::__normal_iterator<int*, std::vector<int> >; typename std::iterator_traits<_Iter>::difference_type = long long int]
next(_ForwardIterator __x, typename
^
0_0_17746626_6612.cpp:210:40: error: call of overloaded 'next(__gnu_cxx::__normal_iterator<int*, std::vector<int> >&)' is ambiguous
root->left = buildTree(next(pre_first), pre_last);
^
0_0_17746626_6612.cpp:210:40: note: candidates are:
0_0_17746626_6612.cpp:120:4: note: II next(II) [with II = __gnu_cxx::__normal_iterator<int*, std::vector<int> >]
II next(II begin)
^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:66:0,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/vector:60,
from 0_0_17746626_6612.cpp:114:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:184:5: note: _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type) [with _ForwardIterator = __gnu_cxx::__normal_iterator<int*, std::vector<int> >; typename std::iterator_traits<_Iter>::difference_type = long long int]
next(_ForwardIterator __x, typename
^
|