From: Daniel Dunbar Date: Tue, 17 Nov 2009 10:04:28 +0000 (+0000) Subject: Merge several visibility tests into hidden-visibility.m, and check .ll output X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3332646a6829adac74e36e12173a57f9e8005a30;p=clang Merge several visibility tests into hidden-visibility.m, and check .ll output not .s output. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89083 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/CodeGenObjC/class-obj-hidden-visibility.m b/test/CodeGenObjC/class-obj-hidden-visibility.m deleted file mode 100644 index 0135bbcac4..0000000000 --- a/test/CodeGenObjC/class-obj-hidden-visibility.m +++ /dev/null @@ -1,6 +0,0 @@ -// RUN: clang-cc -fvisibility=hidden -fobjc-nonfragile-abi -S -o - %s | grep -e "private_extern _OBJC_" | count 2 - -@interface INTF @end - -@implementation INTF @end - diff --git a/test/CodeGenObjC/hidden-synthesized-ivar.m b/test/CodeGenObjC/hidden-synthesized-ivar.m deleted file mode 100644 index c8d999003d..0000000000 --- a/test/CodeGenObjC/hidden-synthesized-ivar.m +++ /dev/null @@ -1,13 +0,0 @@ -// RUN: clang-cc -fobjc-nonfragile-abi -fvisibility=hidden -S -o - %s | grep -e "private_extern _OBJC_IVAR_" -@interface I -{ - int P; -} - -@property int P; -@end - -@implementation I -@synthesize P; -@end - diff --git a/test/CodeGenObjC/hidden-visibility.m b/test/CodeGenObjC/hidden-visibility.m new file mode 100644 index 0000000000..082ee7a70a --- /dev/null +++ b/test/CodeGenObjC/hidden-visibility.m @@ -0,0 +1,25 @@ +// RUN: clang-cc -fvisibility=hidden -fobjc-nonfragile-abi -emit-llvm -o - %s | FileCheck %s +// CHECK: @"OBJC_IVAR_$_I.P" = hidden +// CHECK: @"OBJC_CLASS_$_I" = hidden +// CHECK: @"OBJC_METACLASS_$_I" = hidden +// CHECK: @"\01l_OBJC_PROTOCOL_$_Prot0" = weak hidden + +@interface I { + int P; +} + +@property int P; +@end + +@implementation I +@synthesize P; +@end + + +@protocol Prot0; + +id f0() { + return @protocol(Prot0); +} + + diff --git a/test/CodeGenObjC/protocol-definition-hidden-visibility.m b/test/CodeGenObjC/protocol-definition-hidden-visibility.m deleted file mode 100644 index f63bb03e5c..0000000000 --- a/test/CodeGenObjC/protocol-definition-hidden-visibility.m +++ /dev/null @@ -1,19 +0,0 @@ -// RUN: clang-cc -fobjc-nonfragile-abi -S -o - %s | grep -e "private_extern l_OBJC_PROTOCOL_" | count 2 - -@interface FOO @end - -@interface NSObject @end - -@protocol SSHIPCProtocolHandler_BDC; - -typedef NSObject _SSHIPCProtocolHandler_BDC; - -@interface SSHIPC_v2_RPFSProxy -@property(nonatomic,readonly,retain) _SSHIPCProtocolHandler_BDC* protocolHandler_BDC; -@end - -@implementation FOO -- (_SSHIPCProtocolHandler_BDC*) protocolHandler_BDC {@protocol(SSHIPCProtocolHandler_BDC); } -@end - -