Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ASTReader] Add test for previous change r306583 / 145692e.
Summary: Add a test for the change to ASTReader that reproduces the logic for consolidating multiple ObjC interface definitions to the case of multiple ObjC protocol definitions. This test is a modified copy of the test that accompanied the original change to interfaces, in 2ba1979. Reviewers: bruno Reviewed By: bruno Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D34788 llvm-svn: 306732
- Loading branch information
Showing
5 changed files
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
@protocol BaseProtocol | ||
- (void) test; | ||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include "Base.h" | ||
@protocol DerivedProtocol<BaseProtocol> | ||
- (void) test2; | ||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
#include "Base.h" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
module X { | ||
header "H3.h" | ||
export * | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// RUN: rm -rf %t | ||
// RUN: %clang_cc1 -fmodules-cache-path=%t -fmodules -fimplicit-module-maps -I %S/Inputs/lookup-assert-protocol %s -verify | ||
// expected-no-diagnostics | ||
|
||
#include "Derive.h" | ||
#import <H3.h> | ||
|
||
__attribute__((objc_root_class)) | ||
@interface Thing<DerivedProtocol> | ||
@end | ||
|
||
@implementation Thing | ||
- (void)test { | ||
} | ||
- (void)test2 { | ||
} | ||
@end |