Skip to content

Commit be646ef

Browse files
committed
Make clang/test/C/C2x/n2934.c compatible with targets that do not support thread_local storage.
Add an optional error check to test case for it to pass on targets that do not support thread_local storage. Reviewed By: aaron.ballman, abhina.sreeskantharajan Differential Revision: https://reviews.llvm.org/D145158
1 parent 82f2ce7 commit be646ef

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

clang/test/C/C2x/n2934.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
thread_local struct alignas(int) S { // c2x-warning {{'alignas' is incompatible with C standards before C2x}} \
99
c2x-warning {{'thread_local' is incompatible with C standards before C2x}} \
10+
c2x-error 0+ {{thread-local storage is not supported for the current target}} \
1011
c17-error {{unknown type name 'thread_local'}} \
1112
c17-error {{expected identifier or '('}} \
1213
c17-error {{expected ')'}} \

0 commit comments

Comments
 (0)