view clang/test/SemaObjC/unguarded-availability-category-protocol-use.m @ 266:00f31e85ec16 default tip

Added tag current for changeset 31d058e83c98
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Sat, 14 Oct 2023 10:13:55 +0900
parents 1d019706d866
children
line wrap: on
line source

// RUN: %clang_cc1 -triple arm64-apple-ios10 -Wunguarded-availability -fblocks -fsyntax-only -verify %s

__attribute__((availability(ios,unavailable)))
@protocol Prot // expected-note {{here}}

@end

@interface A
@end

__attribute__((availability(ios,unavailable)))
@interface A (Cat) <Prot> // No error.
@end

__attribute__((availability(tvos,unavailable)))
@interface B @end
@interface B (Cat) <Prot> // expected-error {{'Prot' is unavailable: not available on iOS}}
@end