diff options
author | Douglas Gregor <dgregor@apple.com> | 2010-02-17 16:12:00 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2010-02-17 16:12:00 +0000 |
commit | 2e2a400383c7a64a927f61eeed596b08928e1d4b (patch) | |
tree | 1b10dfa79d3f1e0060ed79b854640bf14d6c5617 /test/ASTMerge/Inputs | |
parent | df3a61bb5148361254c253eccd91aa4517cc8eaa (diff) | |
download | clang-2e2a400383c7a64a927f61eeed596b08928e1d4b.tar.gz |
AST import for Objective-C protocols
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96478 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/ASTMerge/Inputs')
-rw-r--r-- | test/ASTMerge/Inputs/interface1.m | 23 | ||||
-rw-r--r-- | test/ASTMerge/Inputs/interface2.m | 23 |
2 files changed, 46 insertions, 0 deletions
diff --git a/test/ASTMerge/Inputs/interface1.m b/test/ASTMerge/Inputs/interface1.m index bde667475d..a508bc159b 100644 --- a/test/ASTMerge/Inputs/interface1.m +++ b/test/ASTMerge/Inputs/interface1.m @@ -45,3 +45,26 @@ - (int)foo; + (int)bar:(float)x; @end + +// Matching protocol +@protocol P0 ++ (int)foo; +- (int)bar:(float)x; +@end + +// Protocol with mismatching method +@protocol P1 ++ (int)foo; +- (int)bar:(float)x; +@end + +// Interface with protocol +@interface I9 <P0> ++ (int)foo; +- (int)bar:(float)x; +@end + +// Protocol with protocol +@protocol P2 <P0> +- (float)wibble:(int)a1 second:(int)a2; +@end diff --git a/test/ASTMerge/Inputs/interface2.m b/test/ASTMerge/Inputs/interface2.m index 1d5bebd996..d79f77d92a 100644 --- a/test/ASTMerge/Inputs/interface2.m +++ b/test/ASTMerge/Inputs/interface2.m @@ -44,3 +44,26 @@ - (int)foo; + (int)bar:(float)x, ...; @end + +// Matching protocol +@protocol P0 ++ (int)foo; +- (int)bar:(float)x; +@end + +// Protocol with mismatching method +@protocol P1 ++ (int)foo; +- (int)bar:(double)x; +@end + +// Interface with protocol +@interface I9 <P0> ++ (int)foo; +- (int)bar:(float)x; +@end + +// Protocol with protocol +@protocol P2 <P0> +- (float)wibble:(int)a1 second:(int)a2; +@end |