]> granicus.if.org Git - clang/commitdiff
Make the test from r224873 actually pass.
authorNico Weber <nicolasweber@gmx.de>
Sat, 27 Dec 2014 03:38:18 +0000 (03:38 +0000)
committerNico Weber <nicolasweber@gmx.de>
Sat, 27 Dec 2014 03:38:18 +0000 (03:38 +0000)
The behavior looks incorrect to me, but the test is supposed to document
current behavior for now.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@224875 91177308-0d34-0410-b5e6-96231b3b80d8

test/SemaObjC/attr-deprecated.m

index 02acf2ced22d71c5db8784b3db2ababa4f64483c..416e464101113ea57067e02ab798754386ea1858 100644 (file)
@@ -263,9 +263,11 @@ const char * func() {
 @end
 
 @interface InterfaceWithSameMethodAsUndeclaredImpl
-- (void)partiallyUnavailableMethod __attribute__((unavailable));
+- (void)partiallyUnavailableMethod __attribute__((unavailable));  // expected-note{{explicitly marked unavailable here}}
 @end
 
 void f(id a) {
-  [a partiallyUnavailableMethod]; // no warning, `a` could be an UndeclaredImpl.
+  // FIXME: Warning on this looks incorrect, since `a` could be an
+  // UndeclaredImpl object, where this method isn't inavailable.
+  [a partiallyUnavailableMethod]; // expected-error{{is unavailable}}
 }