Make SMDiagnostic a little more sane. Instead of passing around note/warning/error as a
string, pass it around as an enum.
llvm-svn: 142107
diff --git a/llvm/lib/VMCore/LLVMContext.cpp b/llvm/lib/VMCore/LLVMContext.cpp
index ebd1e0a..3ed2c2c 100644
--- a/llvm/lib/VMCore/LLVMContext.cpp
+++ b/llvm/lib/VMCore/LLVMContext.cpp
@@ -100,7 +100,7 @@
}
// If we do have an error handler, we can report the error and keep going.
- SMDiagnostic Diag("", "error: " + ErrorStr.str());
+ SMDiagnostic Diag("", SourceMgr::DK_Error, ErrorStr.str());
pImpl->InlineAsmDiagHandler(Diag, pImpl->InlineAsmDiagContext, LocCookie);
}