diff options
Diffstat (limited to 'llvm/include')
| -rw-r--r-- | llvm/include/llvm/CodeGen/DebugLoc.h | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/llvm/include/llvm/CodeGen/DebugLoc.h b/llvm/include/llvm/CodeGen/DebugLoc.h index 77e8ca505cf..505292846dd 100644 --- a/llvm/include/llvm/CodeGen/DebugLoc.h +++ b/llvm/include/llvm/CodeGen/DebugLoc.h @@ -37,17 +37,14 @@ namespace llvm { public: DebugLoc() : Idx(~0U) {} // Defaults to invalid. - static DebugLoc getUnknownLoc() { DebugLoc L; L.Idx = 0; return L; } + static DebugLoc getUnknownLoc() { DebugLoc L; L.Idx = ~0U; 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; } - /// isUnknown - Return true if there is no debug info for the SDNode / /// MachineInstr. - bool isUnknown() const { return Idx == 0; } + bool isUnknown() const { return Idx == ~0U; } bool operator==(const DebugLoc &DL) const { return Idx == DL.Idx; } bool operator!=(const DebugLoc &DL) const { return !(*this == DL); } |

