From: Aaron Ballman Date: Fri, 8 Dec 2017 02:39:26 +0000 (+0000) Subject: Add a test that the __STDC_VERSION__ macro reports the correct value for -std=c17. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=897706060d72e94587faeb9d3f5862875851d88b;p=clang Add a test that the __STDC_VERSION__ macro reports the correct value for -std=c17. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320131 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/Preprocessor/c17.c b/test/Preprocessor/c17.c new file mode 100644 index 0000000000..c610e84f98 --- /dev/null +++ b/test/Preprocessor/c17.c @@ -0,0 +1,4 @@ +// RUN: %clang_cc1 -fsyntax-only -verify -std=c17 %s +// expected-no-diagnostics + +_Static_assert(__STDC_VERSION__ == 201710L, "Incorrect __STDC_VERSION__");