aboutsummaryrefslogtreecommitdiff
path: root/test/Sema/attr-availability.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Sema/attr-availability.c')
-rw-r--r--test/Sema/attr-availability.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/Sema/attr-availability.c b/test/Sema/attr-availability.c
index f6ed13190e..4dfe65d3d6 100644
--- a/test/Sema/attr-availability.c
+++ b/test/Sema/attr-availability.c
@@ -5,3 +5,15 @@ void f1() __attribute__((availability(ios,obsoleted=2.1,deprecated=3.0))); // e
void f2() __attribute__((availability(ios,introduced=2.1,deprecated=2.1)));
void f3() __attribute__((availability(otheros,introduced=2.2))); // expected-warning{{unknown platform 'otheros' in availability macro}}
+
+// rdar://10095131
+extern void
+ATSFontGetName(const char *oName) __attribute__((availability(macosx,introduced=8.0,deprecated=9.0, message="use CTFontCopyFullName")));
+
+extern void
+ATSFontGetPostScriptName(int flags) __attribute__((availability(macosx,introduced=8.0,obsoleted=9.0, message="use ATSFontGetFullPostScriptName"))); // expected-note {{function has been explicitly marked unavailable here}}
+
+void test_10095131() {
+ ATSFontGetName("Hello"); // expected-warning {{'ATSFontGetName' is deprecated: first deprecated in Mac OS X 9.0 - use CTFontCopyFullName}}
+ ATSFontGetPostScriptName(100); // expected-error {{'ATSFontGetPostScriptName' is unavailable: obsoleted in Mac OS X 9.0 - use ATSFontGetFullPostScriptName}}
+}