summaryrefslogtreecommitdiffstats
path: root/lib/VMCore/Instructions.cpp
diff options
context:
space:
mode:
authorDuncan Sands <baldrick@free.fr>2011-01-04 12:52:29 +0000
committerDuncan Sands <baldrick@free.fr>2011-01-04 12:52:29 +0000
commitc449a224bb5f7ae223106532be60294376f06630 (patch)
tree1c20aa12f3451641868e0c7e7ca21f045248ef6b /lib/VMCore/Instructions.cpp
parentba69d3f6d448ca0a3a56b71fa65e85712bf76512 (diff)
downloadexternal_llvm-c449a224bb5f7ae223106532be60294376f06630.zip
external_llvm-c449a224bb5f7ae223106532be60294376f06630.tar.gz
external_llvm-c449a224bb5f7ae223106532be60294376f06630.tar.bz2
These methods should be "const"; make them so.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122809 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Instructions.cpp')
-rw-r--r--lib/VMCore/Instructions.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/VMCore/Instructions.cpp b/lib/VMCore/Instructions.cpp
index efa390f..f465907 100644
--- a/lib/VMCore/Instructions.cpp
+++ b/lib/VMCore/Instructions.cpp
@@ -2736,14 +2736,14 @@ void CmpInst::swapOperands() {
cast<FCmpInst>(this)->swapOperands();
}
-bool CmpInst::isCommutative() {
- if (ICmpInst *IC = dyn_cast<ICmpInst>(this))
+bool CmpInst::isCommutative() const {
+ if (const ICmpInst *IC = dyn_cast<ICmpInst>(this))
return IC->isCommutative();
return cast<FCmpInst>(this)->isCommutative();
}
-bool CmpInst::isEquality() {
- if (ICmpInst *IC = dyn_cast<ICmpInst>(this))
+bool CmpInst::isEquality() const {
+ if (const ICmpInst *IC = dyn_cast<ICmpInst>(this))
return IC->isEquality();
return cast<FCmpInst>(this)->isEquality();
}