aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-01-28 04:35:52 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-01-28 04:35:52 +0000
commit82e6411d004064a29f03a3ea8b8919f297bfa843 (patch)
tree4409a4ad2916e88c721eca3e8439b4721c2dab16
parent394f7b650a03d5d4d8f740d6765f257b1c4e2ec0 (diff)
DiagnosticsEngine::setMappingToAllDiagnostics() does not need to return bool,
caught by Chad. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149173 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/clang/Basic/Diagnostic.h2
-rw-r--r--lib/Basic/Diagnostic.cpp4
2 files changed, 2 insertions, 4 deletions
diff --git a/include/clang/Basic/Diagnostic.h b/include/clang/Basic/Diagnostic.h
index c587a1d6e2..3aa1d55c10 100644
--- a/include/clang/Basic/Diagnostic.h
+++ b/include/clang/Basic/Diagnostic.h
@@ -479,7 +479,7 @@ public:
/// \brief Add the specified mapping to all diagnostics. Mainly to be used
/// by -Wno-everything to disable all warnings but allow subsequent -W options
/// to enable specific warnings.
- bool setMappingToAllDiagnostics(diag::Mapping Map,
+ void setMappingToAllDiagnostics(diag::Mapping Map,
SourceLocation Loc = SourceLocation());
bool hasErrorOccurred() const { return ErrorOccurred; }
diff --git a/lib/Basic/Diagnostic.cpp b/lib/Basic/Diagnostic.cpp
index eab79d6442..369c32dc12 100644
--- a/lib/Basic/Diagnostic.cpp
+++ b/lib/Basic/Diagnostic.cpp
@@ -295,7 +295,7 @@ bool DiagnosticsEngine::setDiagnosticGroupErrorAsFatal(StringRef Group,
return false;
}
-bool DiagnosticsEngine::setMappingToAllDiagnostics(diag::Mapping Map,
+void DiagnosticsEngine::setMappingToAllDiagnostics(diag::Mapping Map,
SourceLocation Loc) {
// Get all the diagnostics.
llvm::SmallVector<diag::kind, 64> AllDiags;
@@ -305,8 +305,6 @@ bool DiagnosticsEngine::setMappingToAllDiagnostics(diag::Mapping Map,
for (unsigned i = 0, e = AllDiags.size(); i != e; ++i)
if (Diags->isBuiltinWarningOrExtension(AllDiags[i]))
setDiagnosticMapping(AllDiags[i], Map, Loc);
-
- return false;
}
void DiagnosticsEngine::Report(const StoredDiagnostic &storedDiag) {