annotate clang/test/SemaObjC/avoid-unavailable-implementation-warning-in-app-extension.m @ 207:2e18cbf3894f

LLVM12
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Tue, 08 Jun 2021 06:07:14 +0900
parents 1d019706d866
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 // RUN: %clang_cc1 -triple arm64-apple-ios11 -fapplication-extension -Wdeprecated-implementations -verify -Wno-objc-root-class %s
anatofuz
parents:
diff changeset
2 // RUN: %clang_cc1 -triple arm64-apple-tvos11 -fapplication-extension -Wdeprecated-implementations -verify -Wno-objc-root-class %s
anatofuz
parents:
diff changeset
3 // Declarations marked as 'unavailable' in an app extension should not generate a
anatofuz
parents:
diff changeset
4 // warning on implementation.
anatofuz
parents:
diff changeset
5
anatofuz
parents:
diff changeset
6 @interface Parent
anatofuz
parents:
diff changeset
7 - (void)ok __attribute__((availability(ios_app_extension,unavailable,message="not available")));
anatofuz
parents:
diff changeset
8 - (void)reallyUnavail __attribute__((availability(ios,unavailable))); // expected-note {{method 'reallyUnavail' declared here}}
anatofuz
parents:
diff changeset
9 - (void)reallyUnavail2 __attribute__((unavailable)); // expected-note {{method 'reallyUnavail2' declared here}}
anatofuz
parents:
diff changeset
10 @end
anatofuz
parents:
diff changeset
11
anatofuz
parents:
diff changeset
12 @interface Child : Parent
anatofuz
parents:
diff changeset
13 @end
anatofuz
parents:
diff changeset
14
anatofuz
parents:
diff changeset
15 @implementation Child
anatofuz
parents:
diff changeset
16
anatofuz
parents:
diff changeset
17 - (void)ok { // no warning.
anatofuz
parents:
diff changeset
18 }
anatofuz
parents:
diff changeset
19 - (void)reallyUnavail { // expected-warning {{implementing unavailable method}}
anatofuz
parents:
diff changeset
20 }
anatofuz
parents:
diff changeset
21 - (void)reallyUnavail2 { // expected-warning {{implementing unavailable method}}
anatofuz
parents:
diff changeset
22 }
anatofuz
parents:
diff changeset
23
anatofuz
parents:
diff changeset
24 @end