summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
9ca0ce4)
Subtracting anything from an empty range should return an empty range, not an assert() failure
Range (T f, T t) : from (f), to (t) {}
T from; ///< start of the range
T to; ///< end of the range (inclusive: to lies inside the range)
Range (T f, T t) : from (f), to (t) {}
T from; ///< start of the range
T to; ///< end of the range (inclusive: to lies inside the range)
+ bool empty() const { return from == to; }
RangeList<T> result;
result.add (range);
RangeList<T> result;
result.add (range);
+ if (sub.empty () || range.empty()) {