Record Detail

Compile Error

In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp: In constructor 'KDTree<std::tuple<_Elements ...>, ValueType>::KDTree(std::vector<std::pair<std::tuple<_Elements ...>, ValueType> >)':
/in/kdtree.hpp:403:33: error: there are no arguments to 'rbegin' that depend on a template parameter, so a declaration of 'rbegin' must be available [-fpermissive]
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                 ^~~~~~
/in/kdtree.hpp:403:33: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
/in/kdtree.hpp:403:45: error: there are no arguments to 'rend' that depend on a template parameter, so a declaration of 'rend' must be available [-fpermissive]
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                             ^~~~
/in/kdtree.hpp: In instantiation of 'KDTree<std::tuple<_Elements ...>, ValueType>::KDTree(std::vector<std::pair<std::tuple<_Elements ...>, ValueType> >) [with ValueType = std::__cxx11::basic_string<char>; KeyTypes = {int, int, int}]':
/in/driver/main.cpp:43:57:   required from here
/in/kdtree.hpp:403:39: error: no matching function for call to 'rbegin()'
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                 ~~~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:138:5: note: candidate: template<class _Container> constexpr decltype (__cont.rbegin()) std::rbegin(_Container&)
     rbegin(_Container& __cont) -> decltype(__cont.rbegin())
     ^~~~~~
/usr/include/c++/7/bits/range_access.h:138:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:39: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                 ~~~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:148:5: note: candidate: template<class _Container> constexpr decltype (__cont.rbegin()) std::rbegin(const _Container&)
     rbegin(const _Container& __cont) -> decltype(__cont.rbegin())
     ^~~~~~
/usr/include/c++/7/bits/range_access.h:148:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:39: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                 ~~~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:178:5: note: candidate: template<class _Tp, long unsigned int _Nm> constexpr std::reverse_iterator<_Tp*> std::rbegin(_Tp (&)[_Nm])
     rbegin(_Tp (&__arr)[_Nm])
     ^~~~~~
/usr/include/c++/7/bits/range_access.h:178:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:39: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                 ~~~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:198:5: note: candidate: template<class _Tp> constexpr std::reverse_iterator<const _Tp*> std::rbegin(std::initializer_list<_Tp>)
     rbegin(initializer_list<_Tp> __il)
     ^~~~~~
/usr/include/c++/7/bits/range_access.h:198:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:39: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                 ~~~~~~^~
/in/kdtree.hpp:403:49: error: no matching function for call to 'rend()'
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                             ~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:158:5: note: candidate: template<class _Container> constexpr decltype (__cont.rend()) std::rend(_Container&)
     rend(_Container& __cont) -> decltype(__cont.rend())
     ^~~~
/usr/include/c++/7/bits/range_access.h:158:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:49: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                             ~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:168:5: note: candidate: template<class _Container> constexpr decltype (__cont.rend()) std::rend(const _Container&)
     rend(const _Container& __cont) -> decltype(__cont.rend())
     ^~~~
/usr/include/c++/7/bits/range_access.h:168:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:49: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                             ~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:188:5: note: candidate: template<class _Tp, long unsigned int _Nm> constexpr std::reverse_iterator<_Tp*> std::rend(_Tp (&)[_Nm])
     rend(_Tp (&__arr)[_Nm])
     ^~~~
/usr/include/c++/7/bits/range_access.h:188:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:49: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                             ~~~~^~
In file included from /usr/include/c++/7/string:51:0,
                 from /usr/include/c++/7/stdexcept:39,
                 from /usr/include/c++/7/array:39,
                 from /usr/include/c++/7/tuple:39,
                 from /in/kdtree.hpp:1,
                 from /in/driver/main.cpp:8:
/usr/include/c++/7/bits/range_access.h:208:5: note: candidate: template<class _Tp> constexpr std::reverse_iterator<const _Tp*> std::rend(std::initializer_list<_Tp>)
     rend(initializer_list<_Tp> __il)
     ^~~~
/usr/include/c++/7/bits/range_access.h:208:5: note:   template argument deduction/substitution failed:
In file included from /in/driver/main.cpp:8:0:
/in/kdtree.hpp:403:49: note:   candidate expects 1 argument, 0 provided
         auto it = std::unique(v,rbegin(), v,rend(), [](const auto& a, const auto& b){return a.first =- b.first;}).base();
                                             ~~~~^~

Information

Submit By
Type
Submission
Homework
Project 3
Language
C++
Submit At
2024-07-21 22:36:06
Judged At
2024-07-21 22:36:06
Judged By
Score
0
Total Time
0ms
Peak Memory
0 Bytes