[llvm-branch-commits] [clang] ef40d52 - Adding a test case that I accidentally dropped from 27ea7d0a6e0dc51e0214707bcc265fa6f9dc9bc6

Aaron Ballman via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Tue Dec 15 12:00:59 PST 2020


Author: Aaron Ballman
Date: 2020-12-15T14:56:44-05:00
New Revision: ef40d5233b8b6f82927128c5b255cdc3aed9021d

URL: https://github.com/llvm/llvm-project/commit/ef40d5233b8b6f82927128c5b255cdc3aed9021d
DIFF: https://github.com/llvm/llvm-project/commit/ef40d5233b8b6f82927128c5b255cdc3aed9021d.diff

LOG: Adding a test case that I accidentally dropped from 27ea7d0a6e0dc51e0214707bcc265fa6f9dc9bc6

Added: 
    clang/test/Parser/attr-availability-xcore.c

Modified: 
    

Removed: 
    


################################################################################
diff  --git a/clang/test/Parser/attr-availability-xcore.c b/clang/test/Parser/attr-availability-xcore.c
new file mode 100644
index 000000000000..0b354a3d01e8
--- /dev/null
+++ b/clang/test/Parser/attr-availability-xcore.c
@@ -0,0 +1,11 @@
+// Test availability message string type when wide characters are 1 byte.
+// REQUIRES: xcore-registered-target
+// RUN: %clang_cc1 -triple xcore -fsyntax-only -verify %s
+
+#if !__has_feature(attribute_availability)
+#  error 'availability' attribute is not available
+#endif
+
+void f7() __attribute__((availability(macosx,message=L"wide"))); // expected-error {{expected string literal for optional message in 'availability' attribute}}
+
+void f8() __attribute__((availability(macosx,message="a" L"b"))); // expected-error {{expected string literal for optional message in 'availability' attribute}}


        


More information about the llvm-branch-commits mailing list