]> granicus.if.org Git - clang/commitdiff
getNumErrors() -> hasErrorOccurred()
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>
Fri, 19 Nov 2010 00:19:18 +0000 (00:19 +0000)
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>
Fri, 19 Nov 2010 00:19:18 +0000 (00:19 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@119765 91177308-0d34-0410-b5e6-96231b3b80d8

lib/FrontendTool/ExecuteCompilerInvocation.cpp
tools/driver/cc1as_main.cpp

index 63c6287807626126ede7c818cd924af6bb850474..861117fb30a547de452ba3d351c0a67e58a3b7dc 100644 (file)
@@ -141,7 +141,7 @@ bool clang::ExecuteCompilerInvocation(CompilerInstance *Clang) {
 
   // If there were errors in processing arguments, don't do anything else.
   bool Success = false;
-  if (!Clang->getDiagnostics().getNumErrors()) {
+  if (!Clang->getDiagnostics().hasErrorOccurred()) {
     // Create and execute the frontend action.
     llvm::OwningPtr<FrontendAction> Act(CreateFrontendAction(*Clang));
     if (Act) {
index 6159f4b192e9745d849a80d1c40756cbcd893820..fb68d07ab25b9fc17ac1c83cd88cd454104741db 100644 (file)
@@ -368,7 +368,7 @@ int cc1as_main(const char **ArgBegin, const char **ArgEnd,
 
   // Execute the invocation, unless there were parsing errors.
   bool Success = false;
-  if (!Diags.getNumErrors())
+  if (!Diags.hasErrorOccurred())
     Success = ExecuteAssembler(Asm, Diags);
 
   // If any timers were active but haven't been destroyed yet, print their