1 // RUN: %clang_cc1 -E %s -o %t.mm
2 // RUN: %clang_cc1 -x objective-c++ -fblocks -fms-extensions -rewrite-objc %t.mm -o - | FileCheck %s
11 @interface Sub : NSObject {
20 - (id) MyNSString { return subIvar ? PrivateIvar : nsstring; }
23 @interface NSString @end
24 @implementation NSString @end
26 // CHECK: __declspec(allocate(".objc_ivar$B")) extern "C" __declspec(dllimport) unsigned long OBJC_IVAR_$_Sub$subIvar;
27 // CHECK: __declspec(allocate(".objc_ivar$B")) extern "C" unsigned long OBJC_IVAR_$_Sub$PrivateIvar;
28 // CHECK: __declspec(allocate(".objc_ivar$B")) extern "C" __declspec(dllimport) unsigned long OBJC_IVAR_$_Sub$nsstring;
29 // CHECK: #pragma warning(disable:4273)
30 // CHECK: __declspec(allocate(".objc_ivar$B")) extern "C" __declspec(dllexport) unsigned long int OBJC_IVAR_$_Sub$subIvar
31 // CHECK: __declspec(allocate(".objc_ivar$B")) extern "C" __declspec(dllexport) unsigned long int OBJC_IVAR_$_Sub$nsstring
32 // CHECK: __declspec(allocate(".objc_ivar$B")) extern "C" unsigned long int OBJC_IVAR_$_Sub$PrivateIvar
33 // CHECK: extern "C" __declspec(dllimport) struct _class_t OBJC_METACLASS_$_NSObject;
34 // CHECK: extern "C" __declspec(dllexport) struct _class_t OBJC_METACLASS_$_Sub
35 // CHECK: extern "C" __declspec(dllimport) struct _class_t OBJC_CLASS_$_NSObject;
36 // CHECK: extern "C" __declspec(dllexport) struct _class_t OBJC_CLASS_$_Sub
37 // CHECK: extern "C" __declspec(dllexport) struct _class_t OBJC_CLASS_$_NSString;
38 // CHECK: extern "C" __declspec(dllexport) struct _class_t OBJC_METACLASS_$_NSString
39 // CHECK: extern "C" __declspec(dllexport) struct _class_t OBJC_CLASS_$_NSString