Add getter for the index.
authorBill Wendling <isanbard@gmail.com>
Tue, 3 Feb 2009 22:49:14 +0000 (22:49 +0000)
committerBill Wendling <isanbard@gmail.com>
Tue, 3 Feb 2009 22:49:14 +0000 (22:49 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63675 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/CodeGen/DebugLoc.h

index b89bf6302a085067e4b556b131544f06611102bf..51f5116c75687cfc980ad30a7cc8d8491eb6feb8 100644 (file)
@@ -40,6 +40,8 @@ namespace llvm {
     static DebugLoc getUnknownLoc()   { DebugLoc L; L.Idx = 0;   return L; }
     static DebugLoc get(unsigned idx) { DebugLoc L; L.Idx = idx; return L; }
 
+    unsigned getIndex() const { return Idx; }
+
     /// isInvalid - Return true if the DebugLoc is invalid.
     bool isInvalid() const { return Idx == ~0U; }