diff options
author | Chris Lattner <sabre@nondot.org> | 2011-10-16 05:47:55 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2011-10-16 05:47:55 +0000 |
commit | 462b43cbf61fd38db5f2467175c4a51ac1aba154 (patch) | |
tree | 9bc2d6bc21862417ddda16ef92d48a0b369b77c1 /include | |
parent | 3f2d5f60b31fd057c10f77b2e607b23a8c94f6d3 (diff) | |
download | llvm-462b43cbf61fd38db5f2467175c4a51ac1aba154.tar.gz llvm-462b43cbf61fd38db5f2467175c4a51ac1aba154.tar.bz2 llvm-462b43cbf61fd38db5f2467175c4a51ac1aba154.tar.xz |
remove the dead 'ShowLine' argument from SMDiagnostic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142108 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/Support/SourceMgr.h | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/include/llvm/Support/SourceMgr.h b/include/llvm/Support/SourceMgr.h index 9203e67779..4c0d9927fa 100644 --- a/include/llvm/Support/SourceMgr.h +++ b/include/llvm/Support/SourceMgr.h @@ -126,8 +126,7 @@ public: /// specified string. /// void PrintMessage(SMLoc Loc, DiagKind Kind, const Twine &Msg, - ArrayRef<SMRange> Ranges = ArrayRef<SMRange>(), - bool ShowLine = true) const; + ArrayRef<SMRange> Ranges = ArrayRef<SMRange>()) const; /// GetMessage - Return an SMDiagnostic at the specified location with the @@ -135,10 +134,8 @@ public: /// /// @param Type - If non-null, the kind of message (e.g., "error") which is /// prefixed to the message. - /// @param ShowLine - Should the diagnostic show the source line. SMDiagnostic GetMessage(SMLoc Loc, DiagKind Kind, const Twine &Msg, - ArrayRef<SMRange> Ranges = ArrayRef<SMRange>(), - bool ShowLine = true) const; + ArrayRef<SMRange> Ranges = ArrayRef<SMRange>()) const; /// PrintIncludeStack - Prints the names of included files and the line of the /// file they were included from. A diagnostic handler can use this before @@ -159,24 +156,23 @@ class SMDiagnostic { int LineNo, ColumnNo; SourceMgr::DiagKind Kind; std::string Message, LineContents; - unsigned ShowLine : 1; std::vector<std::pair<unsigned, unsigned> > Ranges; public: // Null diagnostic. SMDiagnostic() - : SM(0), LineNo(0), ColumnNo(0), Kind(SourceMgr::DK_Error), ShowLine(0) {} + : SM(0), LineNo(0), ColumnNo(0), Kind(SourceMgr::DK_Error) {} // Diagnostic with no location (e.g. file not found, command line arg error). SMDiagnostic(const std::string &filename, SourceMgr::DiagKind Kind, const std::string &Msg) : SM(0), Filename(filename), LineNo(-1), ColumnNo(-1), Kind(Kind), - Message(Msg), ShowLine(false) {} + Message(Msg) {} // Diagnostic with a location. SMDiagnostic(const SourceMgr &sm, SMLoc L, const std::string &FN, int Line, int Col, SourceMgr::DiagKind Kind, const std::string &Msg, const std::string &LineStr, - ArrayRef<std::pair<unsigned,unsigned> > Ranges, bool showline); + ArrayRef<std::pair<unsigned,unsigned> > Ranges); const SourceMgr *getSourceMgr() const { return SM; } SMLoc getLoc() const { return Loc; } @@ -186,7 +182,6 @@ public: SourceMgr::DiagKind getKind() const { return Kind; } const std::string &getMessage() const { return Message; } const std::string &getLineContents() const { return LineContents; } - bool getShowLine() const { return ShowLine; } const std::vector<std::pair<unsigned, unsigned> > &getRanges() const { return Ranges; } |