summaryrefslogtreecommitdiffstats
path: root/test/Parser/opencl-storage-class.cl
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2011-10-06 03:01:00 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2011-10-06 03:01:00 +0000
commitb8b0e75aeec85a7a268fdba311de4f1cd527fae1 (patch)
treef96f03a46b2e2e9258152696400b54d7a6610032 /test/Parser/opencl-storage-class.cl
parent41c8d6fe09624ea31f5641dd53b6f0b6368ffcdd (diff)
OpenCL: add a non-standard extension, cl_clang_storage_class_specifiers,
which enables support for C99 storage-class specifiers. This extension is intended to be used by implementations to implement OpenCL C built-in functions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141271 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Parser/opencl-storage-class.cl')
-rw-r--r--test/Parser/opencl-storage-class.cl6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Parser/opencl-storage-class.cl b/test/Parser/opencl-storage-class.cl
index d479358f00..874329b62d 100644
--- a/test/Parser/opencl-storage-class.cl
+++ b/test/Parser/opencl-storage-class.cl
@@ -6,4 +6,10 @@ void test_storage_class_specs()
register int b; // expected-error {{OpenCL does not support the 'register' storage class specifier}}
extern int c; // expected-error {{OpenCL does not support the 'extern' storage class specifier}}
auto int d; // expected-error {{OpenCL does not support the 'auto' storage class specifier}}
+
+#pragma OPENCL EXTENSION cl_clang_storage_class_specifiers : enable
+ static int e;
+ register int f;
+ extern int g;
+ auto int h;
}