Borderou de evaluare (job #1150726)
Utilizator | Data | 23 martie 2014 14:36:53 | |
---|---|---|---|
Problema | Tri2 | Status | done |
Runda | Arhiva de probleme | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘bool cmp(const punct&, const punct&)’:
user.cpp:28:24: error: reference to ‘ref’ is ambiguous
return atan2(A.y - ref.y, A.x - ref.x) < atan2(B.y - ref.y, B.x - ref.x);
^
user.cpp:21:25: note: candidates are: punct ref
punct a[NMax], v[NMax], ref, v2[NMax];
^
In file included from /usr/local/include/c++/4.8.0/bits/stl_algo.h:66:0,
from /usr/local/include/c++/4.8.0/algorithm:62,
from user.cpp:3:
/usr/local/include/c++/4.8.0/functional:493:5: note: template<class _Tp> std::reference_wrapper<_Tp> std::ref(std::reference_wrapper<_Tp>)
ref(reference_wrapper<_Tp> __t) noexcept
^
/usr/local/include/c++/4.8.0/functional:485:10: note: template<class _Tp> void std::ref(const _Tp&&)
void ref(const _Tp&&) = delete;
^
/usr/local/include/c++/4.8.0/functional:475:5: note: template<class _Tp> std::reference_wrapper<_Tp> std::ref(_Tp&)
ref(_Tp& __t) noexcept
^
user.cpp:28:37: error: reference to ‘ref’ is ambiguous
return atan2(A.y - ref.y, A.x - ref.x) < atan2(B.y - ref.y, B.x - ref.x);
^
user.cpp:21:25: note: candidates are: punct ref
punct a[NMax], v[NMax], ref, v2[NMax];
^
In file included from /usr/local/include/c++/4.8.0/bits/stl_algo.h:66:0,
from /usr/local/include/c++/4.8.0/algorithm:62,
from user.cpp:3:
/usr/local/include/c++/4.8.0/functional:493:5: note: template<class _Tp> std::reference_wrapper<_Tp> std::ref(std::reference_wrapper<_Tp>)
ref(reference_wrapper<_Tp> __t) noexcept
^
/usr/local/include/c++/4.8.0/functional:485:10: note: template<class _Tp> void std::ref(const _Tp&&)
void ref(const _Tp&&) = delete;
^
/usr/local/include/c++/4.8.0/functional:475:5: note: template<class _Tp> std::reference_wrapper<_Tp> std::ref(_Tp&)
ref(_Tp& __t) noexcept
^
user.cpp:28:58: error: reference to ‘ref’ is ambiguous
return atan2(A.y - ref.y, A.x - ref.x) < atan2(B.y - ref.y, B.x - ref.x);
^
user.cpp:21:25: note: candidates are: punct ref
punct a[NMax], v[NMax], ref, v2[NMax];
^
In file included from /usr/local/include/c++/4.8.0/bits/stl_algo.h:66:0,
from /usr/local/include/c++/4.8.0/algorithm:62,
from user.cpp:3:
/usr/local/include/c++/4.8.0/functional:493:5: note: template<class _Tp> std::reference_wrapper<_Tp> std::ref(std::reference_wrapper<_Tp>)
ref(reference_wrapper<_Tp> __t) noexcept
^
/usr/local/include/c++/4.8.0/functional:485:10: note: template<class _Tp> void std::ref(const _Tp&&)
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !