Revert r302037
authorAlex Lorenz <arphaman@gmail.com>
Wed, 3 May 2017 16:22:16 +0000 (16:22 +0000)
committerAlex Lorenz <arphaman@gmail.com>
Wed, 3 May 2017 16:22:16 +0000 (16:22 +0000)
The commit caused the following two buildbot failures:

    Clang :: Misc/error-limit-multiple-notes.cpp
    Clang :: Misc/error-limit.c

llvm-svn: 302046

clang/lib/Basic/Diagnostic.cpp
clang/test/Index/KeepGoingWithLotsOfErrors.mm [deleted file]

index 2cd400d..6bdef78 100644 (file)
@@ -146,9 +146,8 @@ void DiagnosticsEngine::SetDelayedDiagnostic(unsigned DiagID, StringRef Arg1,
 }
 
 void DiagnosticsEngine::ReportDelayed() {
-  unsigned ID = DelayedDiagID;
+  Report(DelayedDiagID) << DelayedDiagArg1 << DelayedDiagArg2;
   DelayedDiagID = 0;
-  Report(ID) << DelayedDiagArg1 << DelayedDiagArg2;
   DelayedDiagArg1.clear();
   DelayedDiagArg2.clear();
 }
diff --git a/clang/test/Index/KeepGoingWithLotsOfErrors.mm b/clang/test/Index/KeepGoingWithLotsOfErrors.mm
deleted file mode 100644 (file)
index 0144617..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-// RUN: env CINDEXTEST_KEEP_GOING=1 c-index-test -code-completion-at=%s:25:1 %s
-// Shouldn't crash!
-// This is the minimized test that triggered an infinite loop:
-
-+(BOOL) onEntity {
-}
-
--(const Object &) a_200 {
-}
-
--(int) struct {
-}
-
--(int) bar {
-}
-
--(int) part {
-}
-
-+(some_type_t) piece {
-}
-
-+(void) z_Z_42 {
-  ([self onEntity: [] { 42];
-  } class: ^ {  }
-];
-  [super];
-  BOOL struct;
-}