[PATCH] D109857: [test] Fix test failure in Clang :: Lexer/char-escapes-delimited.c

Matthew Voss via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 15 14:54:06 PDT 2021


ormris created this revision.
ormris added reviewers: cor3ntin, aaron.ballman.
ormris requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.

Specify the C and C++ standards explicitly for this test. This avoids failures for drivers that default to older standards.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D109857

Files:
  clang/test/Lexer/char-escapes-delimited.c


Index: clang/test/Lexer/char-escapes-delimited.c
===================================================================
--- clang/test/Lexer/char-escapes-delimited.c
+++ clang/test/Lexer/char-escapes-delimited.c
@@ -1,7 +1,7 @@
-// RUN: %clang_cc1 -fsyntax-only -pedantic -verify %s
-// RUN: %clang_cc1 -x c -fsyntax-only -pedantic -verify %s
-// RUN: %clang_cc1 -fwchar-type=short -fno-signed-wchar -fsyntax-only -pedantic -verify %s
-// RUN: %clang_cc1 -x c -fwchar-type=short -fno-signed-wchar -fsyntax-only -pedantic -verify %s
+// RUN: %clang_cc1 -x c++ -std=gnu++20 -fsyntax-only -pedantic -verify %s
+// RUN: %clang_cc1 -x c -std=gnu2x -fsyntax-only -pedantic -verify %s
+// RUN: %clang_cc1 -x c++ -std=gnu++20 -fwchar-type=short -fno-signed-wchar -fsyntax-only -pedantic -verify %s
+// RUN: %clang_cc1 -x c -std=gnu2x -fwchar-type=short -fno-signed-wchar -fsyntax-only -pedantic -verify %s
 
 const char *errors =
     "\u{}"  //expected-error {{delimited escape sequence cannot be empty}}


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D109857.372812.patch
Type: text/x-patch
Size: 995 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210915/44e81592/attachment-0001.bin>


More information about the cfe-commits mailing list