Commit ddb81059 authored by Daniel Cheng's avatar Daniel Cheng

Force another diagnostic reporting path to be warn-only on Windows.

BUG=467287
R=thakis@chromium.org

Review URL: https://codereview.chromium.org/1095433005

Cr-Commit-Position: refs/heads/master@{#325481}
parent 722d8721
...@@ -95,9 +95,13 @@ void ChromeClassTester::emitWarning(SourceLocation loc, ...@@ -95,9 +95,13 @@ void ChromeClassTester::emitWarning(SourceLocation loc,
std::string err; std::string err;
err = "[chromium-style] "; err = "[chromium-style] ";
err += raw_error; err += raw_error;
// TODO(dcheng): Re-enable -Werror for these diagnostics on Windows once all
// the pre-existing warnings are cleaned up. https://crbug.com/467287
DiagnosticIDs::Level level = DiagnosticIDs::Level level =
#if !defined(LLVM_ON_WIN32)
diagnostic().getWarningsAsErrors() ? diagnostic().getWarningsAsErrors() ?
DiagnosticIDs::Error : DiagnosticIDs::Error :
#endif
DiagnosticIDs::Warning; DiagnosticIDs::Warning;
unsigned id = diagnostic().getDiagnosticIDs()->getCustomDiagID(level, err); unsigned id = diagnostic().getDiagnosticIDs()->getCustomDiagID(level, err);
DiagnosticBuilder builder = diagnostic().Report(full, id); DiagnosticBuilder builder = diagnostic().Report(full, id);
......
...@@ -560,8 +560,8 @@ FindBadConstructsConsumer::CheckRecordForRefcountIssue( ...@@ -560,8 +560,8 @@ FindBadConstructsConsumer::CheckRecordForRefcountIssue(
// -Werror. // -Werror.
DiagnosticsEngine::Level FindBadConstructsConsumer::getErrorLevel() { DiagnosticsEngine::Level FindBadConstructsConsumer::getErrorLevel() {
#if defined(LLVM_ON_WIN32) #if defined(LLVM_ON_WIN32)
// Only warn on Windows, since there are a lot of potential pre-existing // TODO(dcheng): Re-enable -Werror for these diagnostics on Windows once all
// issues. // the pre-existing warnings are cleaned up. https://crbug.com/467287
return DiagnosticsEngine::Warning; return DiagnosticsEngine::Warning;
#else #else
return diagnostic().getWarningsAsErrors() ? DiagnosticsEngine::Error return diagnostic().getWarningsAsErrors() ? DiagnosticsEngine::Error
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment