From 4f7e7882e9972ec567a0529a38737cb83324c91b Mon Sep 17 00:00:00 2001 From: Alex Lorenz Date: Wed, 20 Mar 2019 20:02:00 +0000 Subject: Fix implicit ios -> watchOS availability version mapping for versions that have the major number only rdar://48018651 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@356605 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/Sema/attr-availability-watchos.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'test/Sema/attr-availability-watchos.c') diff --git a/test/Sema/attr-availability-watchos.c b/test/Sema/attr-availability-watchos.c index 866efac6a0..dbcf2c24c6 100644 --- a/test/Sema/attr-availability-watchos.c +++ b/test/Sema/attr-availability-watchos.c @@ -52,3 +52,9 @@ void test_watchos() { f5c_watchos(0); // expected-warning {{'f5c_watchos' is deprecated: first deprecated in watchOS 2.0}} f6_watchos(0); // expected-warning {{'f6_watchos' is deprecated: first deprecated in watchOS 3.0}} } + +void deprecatedAfterIntroduced() __attribute__((availability(ios,introduced=9.3,deprecated=10))); // expected-note {{here}} + +void test_ios_correctly_map_to_watchos() { + deprecatedAfterIntroduced(); // expected-warning {{'deprecatedAfterIntroduced' is deprecated: first deprecated in watchOS 3}} +} -- cgit v1.2.1