Xudong Ni created MESOS-9183:
--------------------------------
Summary: IntervalSet<uint16_t> up bound is one off
Key: MESOS-9183
URL: https://issues.apache.org/jira/browse/MESOS-9183
Project: Mesos
Issue Type: Bug
Components: stout
Reporter: Xudong Ni
the unsigned int 16 range is [0, 65535]; if we tried to set this range, the set
will be "{}"
Example code:
{quote}IntervalSet<uint16_t> set;
set += (Bound<uint16_t>::closed(0), Bound<uint16_t>::closed(65535));
Results: "{}"; Expected: "[0, 65535]"
{quote}
If we decrease the up bound by 1 to 65534, it work normally.
{quote}IntervalSet<uint16_t> set;
set += (Bound<uint16_t>::closed(0), Bound<uint16_t>::closed(65534));
Results: "[0, 65535)"; Expected: "[0, 65535)"
{quote}
It appears the the up bound is one off, since the inervalSet is template, other
type may have the same issue.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)