[cfe-commits] r45842 - /cfe/trunk/Driver/RewriteTest.cpp
Fariborz Jahanian
fjahanian at apple.com
Thu Jan 10 15:04:07 PST 2008
Author: fjahanian
Date: Thu Jan 10 17:04:06 2008
New Revision: 45842
URL: http://llvm.org/viewvc/llvm-project?rev=45842&view=rev
Log:
Avoid redefinition of __objcFastEnumerationState
Modified:
cfe/trunk/Driver/RewriteTest.cpp
Modified: cfe/trunk/Driver/RewriteTest.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Driver/RewriteTest.cpp?rev=45842&r1=45841&r2=45842&view=diff
==============================================================================
--- cfe/trunk/Driver/RewriteTest.cpp (original)
+++ cfe/trunk/Driver/RewriteTest.cpp Thu Jan 10 17:04:06 2008
@@ -122,11 +122,14 @@
"(struct objc_class *, struct objc_object *, ...);\n"
"extern Protocol *objc_getProtocol(const char *);\n"
"#include <objc/objc.h>\n"
+ "#ifndef __FASTENUMERATIONSTATE\n"
"struct __objcFastEnumerationState {\n\t"
"unsigned long state;\n\t"
"id *itemsPtr;\n\t"
"unsigned long *mutationsPtr;\n\t"
- "unsigned long extra[5];\n};\n";
+ "unsigned long extra[5];\n};\n"
+ "#define __FASTENUMERATIONSTATE\n"
+ "#endif\n";
Rewrite.InsertText(SourceLocation::getFileLoc(MainFileID, 0),
s, strlen(s));
More information about the cfe-commits
mailing list