---
utils/TableGen/ClangASTNodesEmitter.cpp | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
---
The result of DeclNodes.inc was unstable on msys, Windows 7 x64.
...Takumi
diff --git a/utils/TableGen/ClangASTNodesEmitter.cpp b/utils/TableGen/ClangASTNodesEmitter.cpp
index 187ab46..289afa3 100644
--- a/utils/TableGen/ClangASTNodesEmitter.cpp
+++ b/utils/TableGen/ClangASTNodesEmitter.cpp
@@ -155,10 +155,14 @@ void ClangDeclContextEmitter::run(raw_ostream &OS) {
}
}
- for (RecordSet::iterator i = DeclContexts.begin(), e = DeclContexts.end();
- i != e; ++i) {
- OS << "DECL_CONTEXT(" << (*i)->getName() << ")\n";
- }
+ // To keep identical order, RecordVector may be used
+ // instead of RecordSet.
+ for (RecordVector::iterator
+ i = DeclContextsVector.begin(),
+ e = DeclContextsVector.end();
+ i != e; ++i)
+ if (DeclContexts.find(*i) != DeclContexts.end())
+ OS << "DECL_CONTEXT(" << (*i)->getName() << ")\n";
OS << "#undef DECL_CONTEXT\n";
OS << "#undef DECL_CONTEXT_BASE\n";
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits