Lines Matching defs:range

75     /// characters. For example, if this class consists of the range `a-z`,
84 let range = self.ranges[i];
85 if let Err(err) = range.case_fold_simple(&mut self.ranges) {
113 // the intersection to the end of this range, and then drain it before
160 // Basically, the easy cases are when neither range overlaps with
161 // each other. If the `b` range is less than our current `a`
162 // range, then we can skip it and move on.
167 // ... similarly for the `a` range. If it's less than the smallest
168 // `b` range, then we can add it as-is.
170 let range = self.ranges[a];
171 self.ranges.push(range);
180 // two things: 1) subtracting a range from another range could
181 // yield two ranges and 2) after subtracting a range, it's possible
184 // range.
186 // For example, if our `a` range is `a-t` and our next three `b`
188 // subtraction three times before moving on to the next `a` range.
189 let mut range = self.ranges[a];
191 && !range.is_intersection_empty(&other.ranges[b])
193 let old_range = range;
194 range = match range.difference(&other.ranges[b]) {
196 // We lost the entire range, so move on to the next
207 // It's possible that the `b` range has more to contribute
209 // range, then it might impact the next `a` range *and* it
210 // has impacted the current `a` range as much as possible,
212 // range can apply it.
216 // Otherwise, the next `b` range might apply to the current
217 // `a` range.
220 self.ranges.push(range);
224 let range = self.ranges[a];
225 self.ranges.push(range);
259 // the negation to the end of this range, and then drain it before
291 // the end of this range, and then drain it before we're done.
294 // If we've added at least one new range, then check if we can
295 // merge this range in the previously added range.
303 let range = self.ranges[oldi];
304 self.ranges.push(range);
362 /// Union the given overlapping range into this range.
374 /// Intersect this range with the given range and return the result.
387 /// Subtract the given range from this range and return the resulting
390 /// If subtraction would result in an empty range, then no ranges are
411 let range = Self::create(lower, self.upper());
413 ret.0 = Some(range);
415 ret.1 = Some(range);
421 /// Compute the symmetric difference the given range from this range. This
449 /// Returns true if and only if the intersection of this range and the
450 /// other range is empty.
457 /// Returns true if and only if this range is a subset of the other range.