]> granicus.if.org Git - clang/commitdiff
Don't emit any timings for GRSimple if the CFG is not going to be built.
authorTed Kremenek <kremenek@apple.com>
Thu, 27 Mar 2008 17:14:42 +0000 (17:14 +0000)
committerTed Kremenek <kremenek@apple.com>
Thu, 27 Mar 2008 17:14:42 +0000 (17:14 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@48882 91177308-0d34-0410-b5e6-96231b3b80d8

Driver/ASTConsumers.cpp

index d58eca5d35a43614d00c9142c92bc7a95e1b4a41..0ae88dd0c8ef866a7d208e0439a0fde9501911d2 100644 (file)
@@ -652,6 +652,9 @@ ASTConsumer* clang::CreateGRSimpleVals(Diagnostic &Diags,
 
 void GRSimpleValsVisitor::VisitCFG(CFG& C, Decl& CD) {
   
+  if (Diags.hasErrorOccurred())
+    return;
+  
   SourceLocation Loc = CD.getLocation();
 
   if (!Loc.isFileID() ||