diff options
author | Douglas Gregor <dgregor@apple.com> | 2013-02-07 19:13:24 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2013-02-07 19:13:24 +0000 |
commit | 560b7fa0c44df3cc4f03b396957aaf7e8e6a8fc8 (patch) | |
tree | ad58d2b0add10e0ac3f549f02e29320ded54b94c /clang/test/Modules | |
parent | 0b62f8a632693b0091f3b2c7a77af18ec9773e09 (diff) | |
download | bcm5719-llvm-560b7fa0c44df3cc4f03b396957aaf7e8e6a8fc8.tar.gz bcm5719-llvm-560b7fa0c44df3cc4f03b396957aaf7e8e6a8fc8.zip |
Retain all hidden methods in the global method pool, because they may become visible <rdar://problem/13172858>.
llvm-svn: 174648
Diffstat (limited to 'clang/test/Modules')
-rw-r--r-- | clang/test/Modules/Inputs/MethodPoolASub.h | 1 | ||||
-rw-r--r-- | clang/test/Modules/Inputs/MethodPoolBSub.h | 1 | ||||
-rw-r--r-- | clang/test/Modules/Inputs/module.map | 4 | ||||
-rw-r--r-- | clang/test/Modules/method_pool.m | 8 |
4 files changed, 14 insertions, 0 deletions
diff --git a/clang/test/Modules/Inputs/MethodPoolASub.h b/clang/test/Modules/Inputs/MethodPoolASub.h index e0bd238567b..0b36dfa6600 100644 --- a/clang/test/Modules/Inputs/MethodPoolASub.h +++ b/clang/test/Modules/Inputs/MethodPoolASub.h @@ -1,3 +1,4 @@ @interface A (Sub) - (char)method3; +- (char*)method4; @end diff --git a/clang/test/Modules/Inputs/MethodPoolBSub.h b/clang/test/Modules/Inputs/MethodPoolBSub.h index 3404ce91fa6..0a7899df81b 100644 --- a/clang/test/Modules/Inputs/MethodPoolBSub.h +++ b/clang/test/Modules/Inputs/MethodPoolBSub.h @@ -1,3 +1,4 @@ @interface B (Sub) - (char *)method3; +- (char*)method4; @end diff --git a/clang/test/Modules/Inputs/module.map b/clang/test/Modules/Inputs/module.map index 234bfcc2b0f..499dcba2799 100644 --- a/clang/test/Modules/Inputs/module.map +++ b/clang/test/Modules/Inputs/module.map @@ -116,6 +116,10 @@ module templates_right { module MethodPoolA { header "MethodPoolA.h" + explicit module Sub2 { + header "MethodPoolASub2.h" + } + explicit module Sub { header "MethodPoolASub.h" } diff --git a/clang/test/Modules/method_pool.m b/clang/test/Modules/method_pool.m index 1b94efb79f9..712e55d4d64 100644 --- a/clang/test/Modules/method_pool.m +++ b/clang/test/Modules/method_pool.m @@ -19,6 +19,10 @@ void testMethod2(id object) { [object method2:1]; } +void testMethod4(id object) { + [object method4]; // expected-warning{{instance method '-method4' not found (return type defaults to 'id')}} +} + @import MethodPoolB; void testMethod1Again(id object) { @@ -46,3 +50,7 @@ void testMethod3AgainAgain(id object) { // expected-note@2{{using}} // expected-note@2{{also found}} } + +void testMethod4Again(id object) { + [object method4]; +} |