diff options
Diffstat (limited to 'lld/Common/ErrorHandler.cpp')
-rw-r--r-- | lld/Common/ErrorHandler.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/lld/Common/ErrorHandler.cpp b/lld/Common/ErrorHandler.cpp index 6dacc2c850b..d1cb3dbbe03 100644 --- a/lld/Common/ErrorHandler.cpp +++ b/lld/Common/ErrorHandler.cpp @@ -65,7 +65,18 @@ void lld::diagnosticHandler(const DiagnosticInfo &DI) { raw_svector_ostream OS(S); DiagnosticPrinterRawOStream DP(OS); DI.print(DP); - warn(S); + switch (DI.getSeverity()) { + case DS_Error: + error(S); + break; + case DS_Warning: + warn(S); + break; + case DS_Remark: + case DS_Note: + message(S); + break; + } } void lld::checkError(Error E) { |