Constify operators.
authorBill Wendling <isanbard@gmail.com>
Fri, 6 Feb 2009 23:17:54 +0000 (23:17 +0000)
committerBill Wendling <isanbard@gmail.com>
Fri, 6 Feb 2009 23:17:54 +0000 (23:17 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63979 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/CodeGen/DebugLoc.h

index d77ee847b6c5c74f2372f3edcd0fea2a238102c8..aa6d8252cfb13770d4dca8da32d0822ddc386a6c 100644 (file)
@@ -49,8 +49,8 @@ namespace llvm {
     /// MachineInstr.
     bool isUnknown() const { return Idx == 0; }
 
-    bool operator==(const DebugLoc &DL) { return Idx == DL.Idx; }
-    bool operator!=(const DebugLoc &DL) { return !(*this == DL); }
+    bool operator==(const DebugLoc &DL) const { return Idx == DL.Idx; }
+    bool operator!=(const DebugLoc &DL) const { return !(*this == DL); }
   };
 
   // Partially specialize DenseMapInfo for DebugLocTyple.