mirror of https://github.com/CGAL/cgal
Fix ambiguous comparisons error with C++20
This commit is contained in:
parent
1d3c8bbbc9
commit
9d16a42257
|
|
@ -48,6 +48,12 @@ public:
|
|||
bool operator!=( const Self& i) const {
|
||||
return !(*this == i);
|
||||
}
|
||||
bool operator==( const Iter& i ) const {
|
||||
return Iter::operator==(i);
|
||||
}
|
||||
bool operator!=( const Iter& i) const {
|
||||
return !(*this == i);
|
||||
}
|
||||
|
||||
Self& operator++() {
|
||||
Move move;
|
||||
|
|
|
|||
|
|
@ -69,6 +69,41 @@ class Nef_polynomial
|
|||
CGAL_STATIC_THREAD_LOCAL_VARIABLE(NT, R_, 1);
|
||||
return R_;
|
||||
}
|
||||
|
||||
friend bool operator==(const Nef_polynomial<NT> &a, const Nef_polynomial<NT> &b)
|
||||
{
|
||||
return a.polynomial() == b.polynomial();
|
||||
}
|
||||
|
||||
friend bool operator==(const Nef_polynomial<NT> &a, const NT& b)
|
||||
{
|
||||
return a.polynomial() == b;
|
||||
}
|
||||
|
||||
friend bool operator==(const Nef_polynomial<NT> &a, int b)
|
||||
{
|
||||
return a.polynomial() == b;
|
||||
}
|
||||
|
||||
friend bool operator<(const Nef_polynomial<NT> &a, const Nef_polynomial<NT> &b)
|
||||
{
|
||||
return a.polynomial() < b.polynomial();
|
||||
}
|
||||
|
||||
friend bool operator<(const Nef_polynomial<NT> &a, const NT& b)
|
||||
{
|
||||
return a.polynomial() < b;
|
||||
}
|
||||
|
||||
friend bool operator<(const Nef_polynomial<NT> &a, int b)
|
||||
{
|
||||
return a.polynomial() < b;
|
||||
}
|
||||
|
||||
friend bool operator>(const Nef_polynomial<NT> &a, int b)
|
||||
{
|
||||
return a.polynomial() > b;
|
||||
}
|
||||
};
|
||||
|
||||
template <class NT>
|
||||
|
|
@ -85,42 +120,6 @@ Nef_polynomial<NT> operator-(const Nef_polynomial<NT> &a)
|
|||
return - a.polynomial();
|
||||
}
|
||||
|
||||
template <class NT>
|
||||
inline
|
||||
bool operator<(const Nef_polynomial<NT> &a, const Nef_polynomial<NT> &b)
|
||||
{
|
||||
return a.polynomial() < b.polynomial();
|
||||
}
|
||||
|
||||
template <class NT>
|
||||
inline
|
||||
bool operator==(const Nef_polynomial<NT> &a, const Nef_polynomial<NT> &b)
|
||||
{
|
||||
return a.polynomial() == b.polynomial();
|
||||
}
|
||||
|
||||
template <class NT>
|
||||
inline
|
||||
bool operator==(const Nef_polynomial<NT> &a, int b)
|
||||
{
|
||||
return a.polynomial() == b;
|
||||
}
|
||||
|
||||
template <class NT>
|
||||
inline
|
||||
bool operator<(const Nef_polynomial<NT> &a, int b)
|
||||
{
|
||||
return a.polynomial() < b;
|
||||
}
|
||||
|
||||
template <class NT>
|
||||
inline
|
||||
bool operator>(const Nef_polynomial<NT> &a, int b)
|
||||
{
|
||||
return a.polynomial() > b;
|
||||
}
|
||||
|
||||
|
||||
#undef CGAL_double
|
||||
#undef CGAL_int
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue