diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2007-10-31 23:08:24 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2007-10-31 23:08:24 +0000 |
commit | 212b768a4b39479bc8cce1268a95a1adbd825542 (patch) | |
tree | 71bad3035e5cad69e708e46f25bbf5a7d8e9483f /Driver/RewriteTest.cpp | |
parent | aff56d0bffdad7ed75db938d5e61e1ce3d5cd195 (diff) |
Fixed a bug exposed by fixing the assert in previous patch (one of the tests asserted).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@43586 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'Driver/RewriteTest.cpp')
-rw-r--r-- | Driver/RewriteTest.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Driver/RewriteTest.cpp b/Driver/RewriteTest.cpp index 4e01dedcb5..257a060ba9 100644 --- a/Driver/RewriteTest.cpp +++ b/Driver/RewriteTest.cpp @@ -544,6 +544,9 @@ void RewriteTest::SynthesizeObjcInternalStruct(ObjcInterfaceDecl *CDecl, std::string &Result) { assert(CDecl && "Class missing in SynthesizeObjcInternalStruct"); assert(CDecl->getName() && "Name missing in SynthesizeObjcInternalStruct"); + // Do not synthesize more than once. + if (ObjcSynthesizedStructs.count(CDecl)) + return; ObjcInterfaceDecl *RCDecl = CDecl->getSuperClass(); if (RCDecl && !ObjcSynthesizedStructs.count(RCDecl)) { // Do it for the root |