Original Post
Hey all, I'm using boost::numeric::interval for its interval intersection routine. When I have two intervals that do not intersect, and I call the intersection routine, it throws an exception about "making an empty interval". But I would like it to make an empty interval! It even has a function to check if an interval is empty: template bool empty(const interval& b); I commented out the exception thrown and continued, but the empty() function above still returned false. What.. the heck?
boost::numeric::interval<int> inter1( 10, 100 );
boost::numeric::interval<int> inter2( 101, 109 );
boost::numeric::interval<int> inter3;
inter3 = boost::numeric::intersect( inter1, inter2 ); // throws boost "empty interval creation" exception