diff options
Diffstat (limited to 'include/llvm/Support/SMLoc.h')
-rw-r--r-- | include/llvm/Support/SMLoc.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/llvm/Support/SMLoc.h b/include/llvm/Support/SMLoc.h index 967bf14..02db327 100644 --- a/include/llvm/Support/SMLoc.h +++ b/include/llvm/Support/SMLoc.h @@ -18,19 +18,19 @@ namespace llvm { // SMLoc - Represents a location in source code. -class SMLoc { +class SMLoc { const char *Ptr; public: SMLoc() : Ptr(0) {} SMLoc(const SMLoc &RHS) : Ptr(RHS.Ptr) {} - + bool isValid() const { return Ptr != 0; } - + bool operator==(const SMLoc &RHS) const { return RHS.Ptr == Ptr; } bool operator!=(const SMLoc &RHS) const { return RHS.Ptr != Ptr; } - + const char *getPointer() const { return Ptr; } - + static SMLoc getFromPointer(const char *Ptr) { SMLoc L; L.Ptr = Ptr; |