summaryrefslogtreecommitdiff
path: root/test/SemaObjC/warn-category-method-deprecated.m
blob: 349a27a795c2f93c4252586e202aa194fac2bc91 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// RUN: %clang_cc1 -fsyntax-only -Wno-objc-root-class -verify %s
// rdar://18013929

@protocol P
- (void)meth;
@end

@interface I <P>
@end

@interface I(cat)
- (void)meth __attribute__((deprecated)); // expected-note {{'meth' has been explicitly marked deprecated here}}
@end

void foo(I *i) {
  [i meth]; // expected-warning {{'meth' is deprecated}}
}