aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2009-07-18 06:34:42 +0000
committerNick Lewycky <nicholas@mxc.ca>2009-07-18 06:34:42 +0000
commit50695f139ae372c9949dfddce603c83f49377b99 (patch)
tree1e69e339c818903ac78cd8ed80335c25c1a5f5d7 /include
parentf32df06245b31a8c6d7336bb40ba0602b0bf2f8a (diff)
downloadexternal_llvm-50695f139ae372c9949dfddce603c83f49377b99.zip
external_llvm-50695f139ae372c9949dfddce603c83f49377b99.tar.gz
external_llvm-50695f139ae372c9949dfddce603c83f49377b99.tar.bz2
Replace intersectWith with maximalIntersectWith. The latter guarantees that
all values belonging to the intersection will belong to the resulting range. The former was inconsistent about that point (either way is fine, just pick one.) This is part of PR4545. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76289 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/llvm/Support/ConstantRange.h16
1 files changed, 4 insertions, 12 deletions
diff --git a/include/llvm/Support/ConstantRange.h b/include/llvm/Support/ConstantRange.h
index cbf3f87..3b72b04 100644
--- a/include/llvm/Support/ConstantRange.h
+++ b/include/llvm/Support/ConstantRange.h
@@ -153,21 +153,13 @@ public:
ConstantRange subtract(const APInt &CI) const;
/// intersectWith - Return the range that results from the intersection of
- /// this range with another range. The resultant range is pruned as much as
- /// possible, but there may be cases where elements are included that are in
- /// one of the sets but not the other. For example: [100, 8) intersect [3,
- /// 120) yields [3, 120)
- ///
- ConstantRange intersectWith(const ConstantRange &CR) const;
-
- /// maximalIntersectWith - Return the range that results from the intersection
- /// of this range with another range. The resultant range is guaranteed to
+ /// this range with another range. The resultant range is guaranteed to
/// include all elements contained in both input ranges, and to have the
/// smallest possible set size that does so. Because there may be two
- /// intersections with the same set size, A.maximalIntersectWith(B) might not
- /// be equal to B.maximalIntersectWith(A).
+ /// intersections with the same set size, A.intersectWith(B) might not
+ /// be equal to B.intersectWith(A).
///
- ConstantRange maximalIntersectWith(const ConstantRange &CR) const;
+ ConstantRange intersectWith(const ConstantRange &CR) const;
/// unionWith - Return the range that results from the union of this range
/// with another range. The resultant range is guaranteed to include the