Merge forward-circular into protocol-test-2

llvm-svn: 68896
This commit is contained in:
Chris Lattner 2009-04-12 08:45:55 +00:00
parent 10644fac2f
commit 7a9c6d2973
2 changed files with 11 additions and 10 deletions

View File

@ -1,10 +0,0 @@
// RUN: clang-cc -fsyntax-only -verify %s
@protocol B;
@protocol C < B > // expected-note{{previous definition is here}}
@end
@protocol A < C >
@end
@protocol B < A > // expected-error{{protocol has circular dependency}}
@end

View File

@ -36,3 +36,14 @@
@protocol YY <XX> // Use of declaration of XX here should not cause a warning.
- zz;
@end
// Detect circular dependencies.
@protocol B;
@protocol C < B > // expected-note{{previous definition is here}}
@end
@protocol A < C >
@end
@protocol B < A > // expected-error{{protocol has circular dependency}}
@end