fix timepos_t::max and timecnt_t::max to avoid int62_t flag bit
Both should likely just re-use int62_t::max
This commit is contained in:
parent
ae01dafcce
commit
baaa8f36ca
@ -450,14 +450,14 @@ struct numeric_limits<Temporal::timepos_t> {
|
|||||||
return Temporal::timepos_t::from_superclock (0);
|
return Temporal::timepos_t::from_superclock (0);
|
||||||
}
|
}
|
||||||
static Temporal::timepos_t max() {
|
static Temporal::timepos_t max() {
|
||||||
return Temporal::timepos_t::from_superclock (4611686018427387904); /* pow (2,62) */
|
return Temporal::timepos_t::from_superclock (4611686018427387903); /* pow (2,62) - 1 */
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
template<>
|
template<>
|
||||||
struct numeric_limits<Temporal::timecnt_t> {
|
struct numeric_limits<Temporal::timecnt_t> {
|
||||||
static Temporal::timecnt_t min() { return Temporal::timecnt_t::from_superclock (0); }
|
static Temporal::timecnt_t min() { return Temporal::timecnt_t::from_superclock (0); }
|
||||||
static Temporal::timecnt_t max() { return Temporal::timecnt_t::from_superclock (4611686018427387904); /* pow (2,62) */ }
|
static Temporal::timecnt_t max() { return Temporal::timecnt_t::from_superclock (4611686018427387903); /* pow (2,62) - 1 */ }
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user