The "real" fix for <rdar://problem/6424347> clang on xcode: Assertion failed: (0 && "unexpected type"), function mergeTypes,
Commit r60845 was premature.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@60852 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/SemaObjC/method-conflict.m b/test/SemaObjC/method-conflict.m
index c46f489..c2fb7ca 100644
--- a/test/SemaObjC/method-conflict.m
+++ b/test/SemaObjC/method-conflict.m
@@ -25,7 +25,8 @@
}
CSSM_FIELDGROUP, *CSSM_FIELDGROUP_PTR;
@protocol XDUMLClassifier;
-@protocol XDUMLClassInterfaceCommons <XDUMLClassifier> @end @protocol XDUMLImplementation;
+@protocol XDUMLClassInterfaceCommons <XDUMLClassifier> // expected-warning {{cannot find protocol definition for 'XDUMLClassifier'}}
+@end @protocol XDUMLImplementation;
@protocol XDUMLElement <NSObject> - (NSArray *) ownedElements;
@end @protocol XDUMLDataType;
@protocol XDUMLNamedElement <XDUMLElement> - (NSString *) name;
@@ -39,7 +40,7 @@
@end @class XDSCOperation;
@interface XDSCClassFormatter : NSObject {
}
-+ (NSUInteger) compartmentsForClassifier: (id <XDUMLClassifier>) classifier withSpecification: (XDSCDisplaySpecification *) displaySpec;
++ (NSUInteger) compartmentsForClassifier: (id <XDUMLClassifier>) classifier withSpecification: (XDSCDisplaySpecification *) displaySpec; // expected-note {{previous definition is here}}
@end
@class NSString;
@implementation XDSCClassFormatter
@@ -47,7 +48,7 @@
+ appendVisibility: (id <XDUMLNamedElement>) element withSpecification: (XDSCDisplaySpecification *) displaySpec to: (NSMutableAttributedString *) attributedString
{
}
-// FIXME: should we warn? (since the protocols are different). FWIW...GCC doesn't currently.
-+ (NSUInteger) compartmentsForClassifier: (id <XDSCClassifier>) classifier withSpecification: (XDSCDisplaySpecification *) displaySpec {
+// GCC doesn't currently warn about this.
++ (NSUInteger) compartmentsForClassifier: (id <XDSCClassifier>) classifier withSpecification: (XDSCDisplaySpecification *) displaySpec { // expected-warning {{conflicting types for 'compartmentsForClassifier:withSpecification:'}}
}
@end
\ No newline at end of file