Fix implementation of timecnt_t::operator==() to compare both duration and position
This commit is contained in:
parent
43c7a39f18
commit
30a00c5e9f
@ -389,8 +389,8 @@ class LIBTEMPORAL_API timecnt_t {
|
|||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool operator!= (timecnt_t const & other) const { return _distance != other.distance(); }
|
bool operator!= (timecnt_t const & other) const { return _distance != other.distance() || _position != other.position(); }
|
||||||
bool operator== (timecnt_t const & other) const { return _distance == other.distance(); }
|
bool operator== (timecnt_t const & other) const { return _distance == other.distance() && _position == other.position(); }
|
||||||
|
|
||||||
/* test for numerical equivalence with a timepos_T. This tests ONLY the
|
/* test for numerical equivalence with a timepos_T. This tests ONLY the
|
||||||
duration in the given domain, NOT position.
|
duration in the given domain, NOT position.
|
||||||
|
Loading…
Reference in New Issue
Block a user