]> granicus.if.org Git - clang/commitdiff
remove #include of system header, making this a) not apple specific, and
authorChris Lattner <sabre@nondot.org>
Wed, 15 Apr 2009 04:26:10 +0000 (04:26 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 15 Apr 2009 04:26:10 +0000 (04:26 +0000)
b) test dramatically faster.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69135 91177308-0d34-0410-b5e6-96231b3b80d8

test/CodeGen/cfstring2.c

index 7b808b4aab40e3267421a9e4f0518cbfc7a5ac4d..ceefeb9e832c50f4d895f1dd7460876f9b4da546 100644 (file)
@@ -1,7 +1,8 @@
 // RUN: clang-cc -emit-llvm %s -o %t
 
-#ifdef __APPLE__
-#include <Carbon/Carbon.h>
+typedef const struct __CFString * CFStringRef;
+
+#define CFSTR(x) (CFStringRef) __builtin___CFStringMakeConstantString (x)
 
 void f() {
   CFSTR("Hello, World!");
@@ -10,4 +11,3 @@ void f() {
 // rdar://6151192
 void *G = CFSTR("yo joe");
 
-#endif