From 63d65f873fdfcb04b216ea9c648d1df5992aed1c Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Tue, 8 Sep 2009 18:19:27 +0000 Subject: Fix PR4922, where Sema would complete tentative definitions in nondeterminstic order because it was doing so while iterating over a densemap. There are still similar problems in other places, for example WeakUndeclaredIdentifiers is still written to the PCH file in a nondeterminstic order, and we emit warnings about #pragma weak in nondeterminstic order. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81236 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Frontend/PCHReader.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/Frontend/PCHReader.cpp') diff --git a/lib/Frontend/PCHReader.cpp b/lib/Frontend/PCHReader.cpp index a7e6c0c8f9..f4d06c068b 100644 --- a/lib/Frontend/PCHReader.cpp +++ b/lib/Frontend/PCHReader.cpp @@ -2225,6 +2225,7 @@ void PCHReader::InitializeSema(Sema &S) { for (unsigned I = 0, N = TentativeDefinitions.size(); I != N; ++I) { VarDecl *Var = cast(GetDecl(TentativeDefinitions[I])); SemaObj->TentativeDefinitions[Var->getDeclName()] = Var; + SemaObj->TentativeDefinitionList.push_back(Var->getDeclName()); } // If there were any locally-scoped external declarations, -- cgit v1.2.3-18-g5258